diff --git a/class/camera.ts b/class/camera.ts index 8e4c53877..53a8472d9 100644 --- a/class/camera.ts +++ b/class/camera.ts @@ -1,8 +1,6 @@ import { Linking, Alert } from 'react-native'; -import { getSystemName } from 'react-native-device-info'; import loc from '../loc'; - -const isDesktop: boolean = getSystemName() === 'Mac OS X'; +import { isDesktop } from '../blue_modules/environment'; export const openPrivacyDesktopSettings = () => { if (isDesktop) { diff --git a/screen/send/psbtMultisigQRCode.js b/screen/send/psbtMultisigQRCode.js index d35da5435..f50418a51 100644 --- a/screen/send/psbtMultisigQRCode.js +++ b/screen/send/psbtMultisigQRCode.js @@ -1,6 +1,5 @@ import React, { useEffect, useRef, useState } from 'react'; import { ActivityIndicator, findNodeHandle, ScrollView, StyleSheet, View } from 'react-native'; -import { getSystemName } from 'react-native-device-info'; import { useNavigation, useRoute, useIsFocused } from '@react-navigation/native'; import { BlueSpacing20 } from '../../BlueComponents'; @@ -13,11 +12,10 @@ import presentAlert from '../../components/Alert'; import { requestCameraAuthorization } from '../../helpers/scan-qr'; import { useTheme } from '../../components/themes'; import SafeArea from '../../components/SafeArea'; +import { isDesktop } from '../../blue_modules/environment'; const bitcoin = require('bitcoinjs-lib'); const fs = require('../../blue_modules/fs'); -const isDesktop = getSystemName() === 'Mac OS X'; - const PsbtMultisigQRCode = () => { const { navigate } = useNavigation(); const { colors } = useTheme(); diff --git a/screen/wallets/addMultisigStep2.js b/screen/wallets/addMultisigStep2.js index 860f37179..00b98ff1f 100644 --- a/screen/wallets/addMultisigStep2.js +++ b/screen/wallets/addMultisigStep2.js @@ -17,7 +17,6 @@ import { } from 'react-native'; import { Icon } from 'react-native-elements'; import { useFocusEffect, useNavigation, useRoute } from '@react-navigation/native'; -import { getSystemName } from 'react-native-device-info'; import { BlueButtonLink, BlueFormMultiInput, BlueSpacing10, BlueSpacing20, BlueText, BlueTextCentered } from '../../BlueComponents'; import navigationStyle from '../../components/navigationStyle'; import { HDSegwitBech32Wallet, MultisigCosigner, MultisigHDWallet } from '../../class'; @@ -38,11 +37,11 @@ import { useTheme } from '../../components/themes'; import Button from '../../components/Button'; import triggerHapticFeedback, { HapticFeedbackTypes } from '../../blue_modules/hapticFeedback'; import usePrivacy from '../../hooks/usePrivacy'; +import { isDesktop } from '../../blue_modules/environment'; const prompt = require('../../helpers/prompt'); const A = require('../../blue_modules/analytics'); const fs = require('../../blue_modules/fs'); -const isDesktop = getSystemName() === 'Mac OS X'; const staticCache = {}; const WalletsAddMultisigStep2 = () => {