@@ -8,11 +8,7 @@ import { useEffect, useState } from "react"
88
99// 3rd part libraries
1010import { Button , Modal } from "@mantine/core"
11- import {
12- useDisclosure ,
13- useLocalStorage ,
14- useSessionStorage ,
15- } from "@mantine/hooks"
11+ import { useDisclosure , useSessionStorage } from "@mantine/hooks"
1612import { Octokit } from "octokit"
1713import semverGt from "semver/functions/gt"
1814
@@ -36,10 +32,6 @@ export default function SingleRunWrapper({ children }) {
3632 defaultValue : false ,
3733 } )
3834
39- const [ isUpdateDismissed , setUpdateDismissed ] = useLocalStorage ( {
40- key : "isUpdateDismissed" ,
41- } )
42-
4335 const { getSetting } = useSettings ( )
4436
4537 useEffect ( ( ) => {
@@ -83,20 +75,12 @@ export default function SingleRunWrapper({ children }) {
8375 if ( getSetting ( "General.autoCheckForUpdates" ) ) checkIfOutOfDate ( )
8476 } , [ ] )
8577
86- // Checks there is an update that the user has not already dismissed
78+ // Checks there is an update
8779 useEffect ( ( ) => {
88- if (
89- fgcsOutOfDateInfo !== null &&
90- isUpdateDismissed !== `${ fgcsOutOfDateInfo ?. latestVersion } `
91- ) {
80+ if ( fgcsOutOfDateInfo !== null ) {
9281 open ( )
9382 }
94- } , [ fgcsOutOfDateInfo , isUpdateDismissed ] )
95-
96- const closeForever = ( ) => {
97- close ( )
98- setUpdateDismissed ( fgcsOutOfDateInfo ?. latestVersion )
99- }
83+ } , [ fgcsOutOfDateInfo ] )
10084
10185 return (
10286 < >
@@ -123,9 +107,6 @@ export default function SingleRunWrapper({ children }) {
123107 fixes.
124108 </ p >
125109 < div className = "flex gap-x-2 mt-5" >
126- < Button component = "a" onClick = { closeForever } fullWidth color = { "red" } >
127- Skip update
128- </ Button >
129110 < Button
130111 component = "a"
131112 href = "https://github.com/Avis-Drone-Labs/FGCS/releases"
0 commit comments