mirror of
https://github.com/MrUnknownDE/VRCX.git
synced 2026-04-27 02:33:48 +02:00
refactor untils
This commit is contained in:
@@ -8,9 +8,9 @@ import {
|
||||
createRateLimiter,
|
||||
executeWithBackoff,
|
||||
getFriendsSortFunction,
|
||||
getUserMemo,
|
||||
isRealInstance
|
||||
} from '../shared/utils';
|
||||
import { getUserMemo } from '../coordinators/memoCoordinator';
|
||||
import { friendRequest, userRequest } from '../api';
|
||||
import {
|
||||
runInitFriendsListFlow,
|
||||
@@ -261,8 +261,6 @@ export const useFriendStore = defineStore('Friend', () => {
|
||||
|
||||
init();
|
||||
|
||||
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
@@ -699,13 +697,11 @@ export const useFriendStore = defineStore('Friend', () => {
|
||||
* @param {string} id
|
||||
*/
|
||||
|
||||
|
||||
/**
|
||||
*
|
||||
* @param {object} ref
|
||||
*/
|
||||
|
||||
|
||||
/**
|
||||
*
|
||||
* @param {object} currentUser
|
||||
@@ -1129,7 +1125,6 @@ export const useFriendStore = defineStore('Friend', () => {
|
||||
* @param id
|
||||
*/
|
||||
|
||||
|
||||
/**
|
||||
* Clears all entries in friendLog.
|
||||
* Uses .clear() instead of reassignment to keep the same Map reference,
|
||||
|
||||
@@ -16,7 +16,7 @@ import {
|
||||
vrcPlusImageRequest
|
||||
} from '../api';
|
||||
import { AppDebug } from '../services/appConfig';
|
||||
import { handleImageUploadInput } from '../shared/utils/imageUpload';
|
||||
import { handleImageUploadInput } from '../coordinators/imageUploadCoordinator';
|
||||
import { router } from '../plugins/router';
|
||||
import { useAdvancedSettingsStore } from './settings/advanced';
|
||||
import { useModalStore } from './modal';
|
||||
|
||||
@@ -13,12 +13,12 @@ import {
|
||||
escapeTag,
|
||||
executeWithBackoff,
|
||||
findUserByDisplayName,
|
||||
getUserMemo,
|
||||
parseLocation,
|
||||
parseNotificationDetails,
|
||||
removeFromArray,
|
||||
sanitizeNotificationJson
|
||||
} from '../../shared/utils';
|
||||
import { getUserMemo } from '../../coordinators/memoCoordinator';
|
||||
import {
|
||||
friendRequest,
|
||||
instanceRequest,
|
||||
@@ -347,11 +347,13 @@ export const useNotificationStore = defineStore('Notification', () => {
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!checkCanInvite(currentLocation, {
|
||||
currentUserId: userStore.currentUser.id,
|
||||
lastLocationStr: locationStore.lastLocation.location,
|
||||
cachedInstances: instanceStore.cachedInstances
|
||||
})) {
|
||||
if (
|
||||
!checkCanInvite(currentLocation, {
|
||||
currentUserId: userStore.currentUser.id,
|
||||
lastLocationStr: locationStore.lastLocation.location,
|
||||
cachedInstances: instanceStore.cachedInstances
|
||||
})
|
||||
) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -8,16 +8,12 @@ import {
|
||||
compareByLocationAt,
|
||||
compareByName,
|
||||
compareByUpdatedAt,
|
||||
getAllUserMemos,
|
||||
getUserMemo,
|
||||
isRealInstance,
|
||||
parseLocation,
|
||||
replaceBioSymbols
|
||||
} from '../shared/utils';
|
||||
import {
|
||||
instanceRequest,
|
||||
userRequest
|
||||
} from '../api';
|
||||
import { getAllUserMemos, getUserMemo } from '../coordinators/memoCoordinator';
|
||||
import { instanceRequest, userRequest } from '../api';
|
||||
import { AppDebug } from '../services/appConfig';
|
||||
import { database } from '../services/database';
|
||||
import { runUpdateCurrentUserLocationFlow } from '../coordinators/locationCoordinator';
|
||||
|
||||
Reference in New Issue
Block a user