Skip to content

Commit

Permalink
Remove react-native-check-version
Browse files Browse the repository at this point in the history
Fixes red error due to server outage
  • Loading branch information
paullinator committed Jun 27, 2024
1 parent d04e68e commit bb4c557
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 33 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

## Unreleased

## 4.8.1

- fixed: Remove react-native-check-version to fix red error

## 4.8.0

- added: "IP Validation Protection Enabled" bottom notification card
Expand Down
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,6 @@
"react-native-airship": "^0.2.12",
"react-native-bootsplash": "^4.7.4",
"react-native-camera": "^1.13.1",
"react-native-check-version": "^1.0.5",
"react-native-confetti-cannon": "^1.5.2",
"react-native-contacts": "^7.0.4",
"react-native-custom-tabs": "https://github.com/adminphoeniixx/react-native-custom-tabs#develop",
Expand Down
28 changes: 1 addition & 27 deletions src/components/scenes/LoginScene.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import { EdgeAccount } from 'edge-core-js'
import { InitialRouteName, LoginScreen } from 'edge-login-ui-rn'
import * as React from 'react'
import { Keyboard, StatusBar, View } from 'react-native'
import { checkVersion } from 'react-native-check-version'
import { BlurView } from 'rn-id-blurview'

import { showSendLogsModal } from '../../actions/LogActions'
Expand All @@ -17,12 +16,10 @@ import { performanceMarkersFromLoginUiPerfEvents } from '../../perf'
import { config } from '../../theme/appConfig'
import { useDispatch, useSelector } from '../../types/reactRedux'
import { EdgeSceneProps } from '../../types/routerTypes'
import { isMaestro } from '../../util/maestro'
import { logEvent } from '../../util/tracking'
import { withServices } from '../hoc/withServices'
import { showHelpModal } from '../modals/HelpModal'
import { UpdateModal } from '../modals/UpdateModal'
import { Airship, showError } from '../services/AirshipInstance'
import { showError } from '../services/AirshipInstance'
import { DotsBackground } from '../ui4/DotsBackground'
import { LoadingScene } from './LoadingScene'

Expand Down Expand Up @@ -52,7 +49,6 @@ export function LoginSceneComponent(props: Props) {

const account = useSelector(state => state.core.account)
const context = useSelector(state => state.core.context)
const disklet = useSelector(state => state.core.disklet)
const pendingDeepLink = useSelector(state => state.pendingDeepLink)
const nextLoginId = useSelector(state => state.nextLoginId)
const loggedIn = useWatch(account, 'loggedIn')
Expand Down Expand Up @@ -112,28 +108,6 @@ export function LoginSceneComponent(props: Props) {
}
}, [account, dispatch, navigation, pendingDeepLink])

const checkForUpdates = useHandler(async () => {
if (isMaestro()) return
const response = await checkVersion()
const skipUpdate = (await disklet.getText('ignoreUpdate.json').catch(() => '')) === response.version
if (response.needsUpdate && !skipUpdate) {
await Airship.show(bridge => (
<UpdateModal
bridge={bridge}
onSkip={() => {
disklet
.setText('ignoreUpdate.json', response.version)
.then(() => bridge.resolve())
.catch(err => bridge.reject(err))
}}
/>
))
}
})
React.useEffect(() => {
checkForUpdates().catch(error => showError(error))
}, [checkForUpdates])

// ---------------------------------------------------------------------
// Handlers
// ---------------------------------------------------------------------
Expand Down
5 changes: 0 additions & 5 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -16376,11 +16376,6 @@ react-native-camera@^1.13.1:
dependencies:
prop-types "^15.6.2"

react-native-check-version@^1.0.5:
version "1.0.5"
resolved "https://registry.yarnpkg.com/react-native-check-version/-/react-native-check-version-1.0.5.tgz#45c622214efbfbb106fd8cfb7cf73d520d21a691"
integrity sha512-AvS1LfImO8NHpy6DYEU7o5Y7ob0pe1k/Q+IQyYAuOETpuTpcLd2TL3bdcV9oGWnp8DL1IOGPXEIIqz+GT/ATfg==

react-native-confetti-cannon@^1.5.2:
version "1.5.2"
resolved "https://registry.yarnpkg.com/react-native-confetti-cannon/-/react-native-confetti-cannon-1.5.2.tgz#ca1a05edd2a64b080ea8b6238c49277908e1f123"
Expand Down

0 comments on commit bb4c557

Please sign in to comment.