Files
Signal-Desktop/ts/util/callingPermissions.ts
Peter Thatcher d3a27a6442 Calling support
2020-07-30 13:08:47 -07:00

11 lines
303 B
TypeScript

export async function requestCameraPermissions(): Promise<boolean> {
if (!(await window.getMediaCameraPermissions())) {
await window.showCallingPermissionsPopup(true);
// Check the setting again (from the source of truth).
return window.getMediaCameraPermissions();
}
return true;
}