separate authenticated endpoints to user.js
This commit is contained in:
parent
04a0b0b8a8
commit
ebf7040662
36 changed files with 1082 additions and 1055 deletions
|
|
@ -11,11 +11,7 @@ import { promiseInterval } from '../services/promise_interval/promise_interval.j
|
|||
|
||||
import { useOAuthStore } from 'src/stores/oauth.js'
|
||||
|
||||
import {
|
||||
chats,
|
||||
deleteChatMessage,
|
||||
readChat,
|
||||
} from 'src/services/api/api.service.js'
|
||||
import { chats, deleteChatMessage, readChat } from 'src/services/api/chats.js'
|
||||
|
||||
const emptyChatList = () => ({
|
||||
data: [],
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
import { markNotificationsAsSeen } from '../services/api/api.service.js'
|
||||
import { markNotificationsAsSeen } from '../services/api/user.js'
|
||||
import {
|
||||
closeAllDesktopNotifications,
|
||||
closeDesktopNotification,
|
||||
|
|
@ -15,7 +15,7 @@ import { useOAuthStore } from 'src/stores/oauth.js'
|
|||
import { useReportsStore } from 'src/stores/reports.js'
|
||||
import { useSyncConfigStore } from 'src/stores/sync_config.js'
|
||||
|
||||
import { dismissNotification } from 'src/services/api/api.service.js'
|
||||
import { dismissNotification } from 'src/services/api/user.js'
|
||||
|
||||
const emptyNotifications = () => ({
|
||||
desktopNotificationSilence: true,
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import { useOAuthStore } from 'src/stores/oauth.js'
|
|||
import {
|
||||
updateNotificationSettings,
|
||||
updateProfile,
|
||||
} from 'src/services/api/api.service.js'
|
||||
} from 'src/services/api/user.js'
|
||||
|
||||
const defaultApi = ({ rootState, commit }, { path, value }) => {
|
||||
const params = {}
|
||||
|
|
|
|||
|
|
@ -13,10 +13,11 @@ import {
|
|||
slice,
|
||||
} from 'lodash'
|
||||
|
||||
import { useInstanceCapabilitiesStore } from 'src/stores/instance_capabilities.js'
|
||||
import { useInterfaceStore } from 'src/stores/interface.js'
|
||||
import { useOAuthStore } from 'src/stores/oauth.js'
|
||||
|
||||
import {
|
||||
bookmarkStatus,
|
||||
deleteStatus,
|
||||
favorite,
|
||||
fetchEmojiReactions,
|
||||
fetchFavoritedByUsers,
|
||||
fetchPinnedStatuses,
|
||||
|
|
@ -25,22 +26,23 @@ import {
|
|||
fetchStatus,
|
||||
fetchStatusHistory,
|
||||
fetchStatusSource,
|
||||
search2,
|
||||
} from 'src/services/api/api.service.js'
|
||||
import {
|
||||
bookmarkStatus,
|
||||
deleteStatus,
|
||||
favorite,
|
||||
muteConversation,
|
||||
pinOwnStatus,
|
||||
reactWithEmoji,
|
||||
retweet,
|
||||
search2,
|
||||
unbookmarkStatus,
|
||||
unfavorite,
|
||||
unmuteConversation,
|
||||
unpinOwnStatus,
|
||||
unreactWithEmoji,
|
||||
unretweet,
|
||||
} from '../services/api/api.service.js'
|
||||
|
||||
import { useInstanceCapabilitiesStore } from 'src/stores/instance_capabilities.js'
|
||||
import { useInterfaceStore } from 'src/stores/interface.js'
|
||||
import { useOAuthStore } from 'src/stores/oauth.js'
|
||||
} from 'src/services/api/user.js'
|
||||
|
||||
const emptyTl = (userId = 0) => ({
|
||||
statuses: [],
|
||||
|
|
|
|||
|
|
@ -32,21 +32,23 @@ import { useSyncConfigStore } from 'src/stores/sync_config.js'
|
|||
import { useUserHighlightStore } from 'src/stores/user_highlight.js'
|
||||
|
||||
import {
|
||||
fetchBlocks,
|
||||
fetchDomainMutes,
|
||||
fetchFollowers,
|
||||
fetchFriends,
|
||||
fetchMutes,
|
||||
fetchUser,
|
||||
fetchUserByName,
|
||||
fetchUserInLists,
|
||||
fetchUserRelationship,
|
||||
followUser,
|
||||
getCaptcha,
|
||||
muteUser,
|
||||
searchUsers,
|
||||
verifyCredentials,
|
||||
} from 'src/services/api/api.service.js'
|
||||
import {
|
||||
fetchBlocks,
|
||||
fetchDomainMutes,
|
||||
fetchMutes,
|
||||
fetchUserInLists,
|
||||
fetchUserRelationship,
|
||||
followUser,
|
||||
muteUser,
|
||||
} from 'src/services/api/user.js'
|
||||
|
||||
// TODO: Unify with mergeOrAdd in statuses.js
|
||||
export const mergeOrAdd = (arr, obj, item) => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue