mirror of
https://github.com/cupcakearmy/unpixel.git
synced 2025-12-14 01:35:03 +00:00
fixed mic
This commit is contained in:
@@ -6,6 +6,7 @@ import Settings from './settings'
|
||||
const exec = promisify(cp.exec)
|
||||
|
||||
export async function isCameraActive(): Promise<boolean> {
|
||||
// Not reliable
|
||||
if (process.platform === 'darwin') {
|
||||
// Check number of processes using the camera
|
||||
const out = await exec(`lsof -n | grep "AppleCamera"`)
|
||||
@@ -42,7 +43,7 @@ export class InputDevicesStatus {
|
||||
|
||||
static areCameraOrMicrophoneActive(): boolean {
|
||||
if (Settings.load('skipOnCameraOrMic')) {
|
||||
return InputDevicesStatus.status.mic || InputDevicesStatus.status.camera
|
||||
return InputDevicesStatus.status.mic
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user