separate authenticated endpoints to user.js
This commit is contained in:
parent
04a0b0b8a8
commit
ebf7040662
36 changed files with 1082 additions and 1055 deletions
|
|
@ -8,10 +8,8 @@ import {
|
|||
editAnnouncement,
|
||||
postAnnouncement,
|
||||
} from 'src/services/api/admin.js'
|
||||
import {
|
||||
dismissAnnouncement,
|
||||
getAnnouncements,
|
||||
} from 'src/services/api/api.service.js'
|
||||
import { getAnnouncements } from 'src/services/api/api.service.js'
|
||||
import { dismissAnnouncement } from 'src/services/api/user.js'
|
||||
|
||||
const FETCH_ANNOUNCEMENT_INTERVAL_MS = 1000 * 60 * 5
|
||||
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ import {
|
|||
deleteBookmarkFolder,
|
||||
fetchBookmarkFolders,
|
||||
updateBookmarkFolder,
|
||||
} from 'src/services/api/api.service.js'
|
||||
} from 'src/services/api/user.js'
|
||||
import { promiseInterval } from 'src/services/promise_interval/promise_interval.js'
|
||||
|
||||
export const useBookmarkFoldersStore = defineStore('bookmarkFolders', {
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ import {
|
|||
getListAccounts,
|
||||
removeAccountsFromList,
|
||||
updateList,
|
||||
} from 'src/services/api/api.service.js'
|
||||
} from 'src/services/api/user.js'
|
||||
import { promiseInterval } from 'src/services/promise_interval/promise_interval.js'
|
||||
|
||||
export const useListsStore = defineStore('lists', {
|
||||
|
|
|
|||
|
|
@ -2,10 +2,7 @@ import { defineStore } from 'pinia'
|
|||
|
||||
import { useOAuthStore } from 'src/stores/oauth.js'
|
||||
|
||||
import {
|
||||
fetchOAuthTokens,
|
||||
revokeOAuthToken,
|
||||
} from 'src/services/api/api.service.js'
|
||||
import { fetchOAuthTokens, revokeOAuthToken } from 'src/services/api/user.js'
|
||||
|
||||
export const useOAuthTokensStore = defineStore('oauthTokens', {
|
||||
state: () => ({
|
||||
|
|
|
|||
|
|
@ -3,7 +3,8 @@ import { defineStore } from 'pinia'
|
|||
|
||||
import { useOAuthStore } from 'src/stores/oauth.js'
|
||||
|
||||
import { fetchPoll, vote } from 'src/services/api/api.service.js'
|
||||
import { fetchPoll } from 'src/services/api/api.service.js'
|
||||
import { vote } from 'src/services/api/user.js'
|
||||
|
||||
export const usePollsStore = defineStore('polls', {
|
||||
state: () => ({
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@ import {
|
|||
validateSetting,
|
||||
} from 'src/modules/default_config_state.js'
|
||||
import { oldDefaultConfigSync } from 'src/modules/old_default_config_state.js'
|
||||
import { updateProfileJSON } from 'src/services/api/api.service.js'
|
||||
import { updateProfileJSON } from 'src/services/api/user.js'
|
||||
|
||||
export const VERSION = 2
|
||||
export const NEW_USER_DATE = new Date('2026-03-16') // date of writing this, basically
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ import { toRaw } from 'vue'
|
|||
import { useOAuthStore } from 'src/stores/oauth.js'
|
||||
|
||||
import { storage } from 'src/lib/storage.js'
|
||||
import { updateProfileJSON } from 'src/services/api/api.service.js'
|
||||
import { updateProfileJSON } from 'src/services/api/user.js'
|
||||
|
||||
export const NEW_USER_DATE = new Date('2022-08-04') // date of writing this, basically
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue