chore: fix lint:js-in-markdown script (#38260)

This commit is contained in:
David Sanders 2023-05-15 00:58:35 -07:00 committed by GitHub
parent 0149ae72e6
commit eeb1e7d499
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
26 changed files with 1078 additions and 586 deletions

View file

@ -24,9 +24,7 @@ function createWindow () {
event.preventDefault()
if (details.deviceList && details.deviceList.length > 0) {
const deviceToReturn = details.deviceList.find((device) => {
if (!grantedDeviceThroughPermHandler || (device.deviceId !== grantedDeviceThroughPermHandler.deviceId)) {
return true
}
return !grantedDeviceThroughPermHandler || (device.deviceId !== grantedDeviceThroughPermHandler.deviceId)
})
if (deviceToReturn) {
callback(deviceToReturn.deviceId)