mirror of
https://github.com/tooot-app/app
synced 2025-06-05 22:19:13 +02:00
Spelling (#449)
* spelling: announcement Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: corrupted Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: dimensions Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: favourites Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: mutation Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: retrieve Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> * spelling: transitive Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
This commit is contained in:
@ -4,7 +4,7 @@ import { displayMessage } from '@components/Message'
|
||||
import navigationRef from '@helpers/navigationRef'
|
||||
import { useAppDispatch } from '@root/store'
|
||||
import { InstanceLatest } from '@utils/migrations/instances/migration'
|
||||
import { getExpoToken, retriveExpoToken } from '@utils/slices/appSlice'
|
||||
import { getExpoToken, retrieveExpoToken } from '@utils/slices/appSlice'
|
||||
import { disableAllPushes } from '@utils/slices/instancesSlice'
|
||||
import { useTheme } from '@utils/styles/ThemeManager'
|
||||
import * as Notifications from 'expo-notifications'
|
||||
@ -22,7 +22,7 @@ const pushUseConnect = ({ t, instances }: Params) => {
|
||||
const dispatch = useAppDispatch()
|
||||
const { theme } = useTheme()
|
||||
useEffect(() => {
|
||||
dispatch(retriveExpoToken())
|
||||
dispatch(retrieveExpoToken())
|
||||
}, [])
|
||||
|
||||
const expoToken = useSelector(getExpoToken)
|
||||
|
@ -54,7 +54,7 @@ const updateStatusProperty = ({
|
||||
const tootIndex = reblog
|
||||
? items.findIndex(({ reblog }) => reblog?.id === id)
|
||||
: items.findIndex(toot => toot.id === id)
|
||||
// if favouriets page and notifications page, remove the item instead
|
||||
// if favourites page and notifications page, remove the item instead
|
||||
if (tootIndex >= 0) {
|
||||
foundToot = true
|
||||
updateStatus({ item: items[tootIndex], reblog, payload })
|
||||
@ -111,7 +111,7 @@ const updateStatusProperty = ({
|
||||
const tootIndex = reblog
|
||||
? items.findIndex(({ reblog }) => reblog?.id === id)
|
||||
: items.findIndex(toot => toot.id === id)
|
||||
// if favouriets page and notifications page, remove the item instead
|
||||
// if favourites page and notifications page, remove the item instead
|
||||
if (tootIndex >= 0) {
|
||||
foundToot = true
|
||||
updateStatus({ item: items[tootIndex], reblog, payload })
|
||||
|
@ -5,7 +5,7 @@ import { isDevelopment } from '@utils/checkEnvironment'
|
||||
import Constants from 'expo-constants'
|
||||
import * as Notifications from 'expo-notifications'
|
||||
|
||||
export const retriveExpoToken = createAsyncThunk(
|
||||
export const retrieveExpoToken = createAsyncThunk(
|
||||
'app/expoToken',
|
||||
async (): Promise<string> => {
|
||||
if (isDevelopment) {
|
||||
@ -20,7 +20,7 @@ export const retriveExpoToken = createAsyncThunk(
|
||||
}
|
||||
)
|
||||
|
||||
export const retriveVersionLatest = createAsyncThunk(
|
||||
export const retrieveVersionLatest = createAsyncThunk(
|
||||
'app/versionUpdate',
|
||||
async (): Promise<string> => {
|
||||
const res = await apiGeneral<{ latest: string }>({
|
||||
@ -48,12 +48,12 @@ const appSlice = createSlice({
|
||||
reducers: {},
|
||||
extraReducers: builder => {
|
||||
builder
|
||||
.addCase(retriveExpoToken.fulfilled, (state, action) => {
|
||||
.addCase(retrieveExpoToken.fulfilled, (state, action) => {
|
||||
if (action.payload) {
|
||||
state.expoToken = action.payload
|
||||
}
|
||||
})
|
||||
.addCase(retriveVersionLatest.fulfilled, (state, action) => {
|
||||
.addCase(retrieveVersionLatest.fulfilled, (state, action) => {
|
||||
if (action.payload && Constants.expoConfig?.version) {
|
||||
if (
|
||||
parseFloat(action.payload) > parseFloat(Constants.expoConfig?.version)
|
||||
|
Reference in New Issue
Block a user