From 813c52f51e5a07a244fe453e9a960c2ec2ec0769 Mon Sep 17 00:00:00 2001 From: syuilo Date: Fri, 22 Feb 2019 14:06:17 +0900 Subject: [PATCH] Remove unused imports --- src/server/api/endpoints/blocking/create.ts | 2 +- src/server/api/endpoints/blocking/delete.ts | 2 +- src/server/api/endpoints/following/create.ts | 2 +- src/server/api/endpoints/following/delete.ts | 2 +- src/server/api/endpoints/following/requests/accept.ts | 1 - src/server/api/endpoints/following/requests/cancel.ts | 2 +- src/server/api/endpoints/following/requests/reject.ts | 1 - src/server/api/endpoints/games/reversi/match.ts | 1 - src/server/api/endpoints/messaging/messages.ts | 1 - src/server/api/endpoints/mute/create.ts | 1 - src/server/api/endpoints/mute/delete.ts | 1 - src/server/api/endpoints/users/get_frequently_replied_users.ts | 2 +- src/server/api/endpoints/users/lists/pull.ts | 2 +- src/server/api/endpoints/users/lists/push.ts | 2 +- src/server/api/endpoints/users/notes.ts | 1 - 15 files changed, 8 insertions(+), 15 deletions(-) diff --git a/src/server/api/endpoints/blocking/create.ts b/src/server/api/endpoints/blocking/create.ts index 0186e1cb09..71c3ed3165 100644 --- a/src/server/api/endpoints/blocking/create.ts +++ b/src/server/api/endpoints/blocking/create.ts @@ -1,7 +1,7 @@ import $ from 'cafy'; import ID, { transform } from '../../../../misc/cafy-id'; import * as ms from 'ms'; -import User, { pack } from '../../../../models/user'; +import { pack } from '../../../../models/user'; import Blocking from '../../../../models/blocking'; import create from '../../../../services/blocking/create'; import define from '../../define'; diff --git a/src/server/api/endpoints/blocking/delete.ts b/src/server/api/endpoints/blocking/delete.ts index 494922e401..426d88c1c0 100644 --- a/src/server/api/endpoints/blocking/delete.ts +++ b/src/server/api/endpoints/blocking/delete.ts @@ -1,7 +1,7 @@ import $ from 'cafy'; import ID, { transform } from '../../../../misc/cafy-id'; import * as ms from 'ms'; -import User, { pack } from '../../../../models/user'; +import { pack } from '../../../../models/user'; import Blocking from '../../../../models/blocking'; import deleteBlocking from '../../../../services/blocking/delete'; import define from '../../define'; diff --git a/src/server/api/endpoints/following/create.ts b/src/server/api/endpoints/following/create.ts index 06f1787a98..a4e68f5806 100644 --- a/src/server/api/endpoints/following/create.ts +++ b/src/server/api/endpoints/following/create.ts @@ -1,7 +1,7 @@ import $ from 'cafy'; import ID, { transform } from '../../../../misc/cafy-id'; import * as ms from 'ms'; -import User, { pack } from '../../../../models/user'; +import { pack } from '../../../../models/user'; import Following from '../../../../models/following'; import create from '../../../../services/following/create'; import define from '../../define'; diff --git a/src/server/api/endpoints/following/delete.ts b/src/server/api/endpoints/following/delete.ts index a6ea551dcd..faa42cacf5 100644 --- a/src/server/api/endpoints/following/delete.ts +++ b/src/server/api/endpoints/following/delete.ts @@ -1,7 +1,7 @@ import $ from 'cafy'; import ID, { transform } from '../../../../misc/cafy-id'; import * as ms from 'ms'; -import User, { pack } from '../../../../models/user'; +import { pack } from '../../../../models/user'; import Following from '../../../../models/following'; import deleteFollowing from '../../../../services/following/delete'; import define from '../../define'; diff --git a/src/server/api/endpoints/following/requests/accept.ts b/src/server/api/endpoints/following/requests/accept.ts index 82cd4e0ca3..cc42ca9c30 100644 --- a/src/server/api/endpoints/following/requests/accept.ts +++ b/src/server/api/endpoints/following/requests/accept.ts @@ -1,7 +1,6 @@ import $ from 'cafy'; import ID, { transform } from '../../../../../misc/cafy-id'; import acceptFollowRequest from '../../../../../services/following/requests/accept'; -import User from '../../../../../models/user'; import define from '../../../define'; import { ApiError } from '../../../error'; import { getUser } from '../../../common/getters'; diff --git a/src/server/api/endpoints/following/requests/cancel.ts b/src/server/api/endpoints/following/requests/cancel.ts index 82c1e792b0..eb3abfa3e6 100644 --- a/src/server/api/endpoints/following/requests/cancel.ts +++ b/src/server/api/endpoints/following/requests/cancel.ts @@ -1,7 +1,7 @@ import $ from 'cafy'; import ID, { transform } from '../../../../../misc/cafy-id'; import cancelFollowRequest from '../../../../../services/following/requests/cancel'; -import User, { pack } from '../../../../../models/user'; +import { pack } from '../../../../../models/user'; import define from '../../../define'; import { ApiError } from '../../../error'; import { getUser } from '../../../common/getters'; diff --git a/src/server/api/endpoints/following/requests/reject.ts b/src/server/api/endpoints/following/requests/reject.ts index 9a134c7dff..908e64acc9 100644 --- a/src/server/api/endpoints/following/requests/reject.ts +++ b/src/server/api/endpoints/following/requests/reject.ts @@ -1,7 +1,6 @@ import $ from 'cafy'; import ID, { transform } from '../../../../../misc/cafy-id'; import rejectFollowRequest from '../../../../../services/following/requests/reject'; -import User from '../../../../../models/user'; import define from '../../../define'; import { ApiError } from '../../../error'; import { getUser } from '../../../common/getters'; diff --git a/src/server/api/endpoints/games/reversi/match.ts b/src/server/api/endpoints/games/reversi/match.ts index 0ae61f9d15..6913ee13d5 100644 --- a/src/server/api/endpoints/games/reversi/match.ts +++ b/src/server/api/endpoints/games/reversi/match.ts @@ -2,7 +2,6 @@ import $ from 'cafy'; import ID, { transform } from '../../../../../misc/cafy-id'; import Matching, { pack as packMatching } from '../../../../../models/games/reversi/matching'; import ReversiGame, { pack as packGame } from '../../../../../models/games/reversi/game'; -import User from '../../../../../models/user'; import { publishMainStream, publishReversiStream } from '../../../../../services/stream'; import { eighteight } from '../../../../../games/reversi/maps'; import define from '../../../define'; diff --git a/src/server/api/endpoints/messaging/messages.ts b/src/server/api/endpoints/messaging/messages.ts index 6eb950d418..34d3f4cfd5 100644 --- a/src/server/api/endpoints/messaging/messages.ts +++ b/src/server/api/endpoints/messaging/messages.ts @@ -1,7 +1,6 @@ import $ from 'cafy'; import ID, { transform } from '../../../../misc/cafy-id'; import Message from '../../../../models/messaging-message'; -import User from '../../../../models/user'; import { pack } from '../../../../models/messaging-message'; import read from '../../common/read-messaging-message'; import define from '../../define'; diff --git a/src/server/api/endpoints/mute/create.ts b/src/server/api/endpoints/mute/create.ts index 45e2080648..3b2546176e 100644 --- a/src/server/api/endpoints/mute/create.ts +++ b/src/server/api/endpoints/mute/create.ts @@ -1,6 +1,5 @@ import $ from 'cafy'; import ID, { transform } from '../../../../misc/cafy-id'; -import User from '../../../../models/user'; import Mute from '../../../../models/mute'; import define from '../../define'; import { ApiError } from '../../error'; diff --git a/src/server/api/endpoints/mute/delete.ts b/src/server/api/endpoints/mute/delete.ts index d9f7025d53..93af5834b8 100644 --- a/src/server/api/endpoints/mute/delete.ts +++ b/src/server/api/endpoints/mute/delete.ts @@ -1,6 +1,5 @@ import $ from 'cafy'; import ID, { transform } from '../../../../misc/cafy-id'; -import User from '../../../../models/user'; import Mute from '../../../../models/mute'; import define from '../../define'; import { ApiError } from '../../error'; diff --git a/src/server/api/endpoints/users/get_frequently_replied_users.ts b/src/server/api/endpoints/users/get_frequently_replied_users.ts index 4c6a040a95..0b90e489c2 100644 --- a/src/server/api/endpoints/users/get_frequently_replied_users.ts +++ b/src/server/api/endpoints/users/get_frequently_replied_users.ts @@ -1,7 +1,7 @@ import $ from 'cafy'; import ID, { transform } from '../../../../misc/cafy-id'; import Note from '../../../../models/note'; -import User, { pack } from '../../../../models/user'; +import { pack } from '../../../../models/user'; import define from '../../define'; import { maximum } from '../../../../prelude/array'; import { getHideUserIds } from '../../common/get-hide-users'; diff --git a/src/server/api/endpoints/users/lists/pull.ts b/src/server/api/endpoints/users/lists/pull.ts index 679b71277c..7c438ff3d6 100644 --- a/src/server/api/endpoints/users/lists/pull.ts +++ b/src/server/api/endpoints/users/lists/pull.ts @@ -1,7 +1,7 @@ import $ from 'cafy'; import ID, { transform } from '../../../../../misc/cafy-id'; import UserList from '../../../../../models/user-list'; -import User, { pack as packUser } from '../../../../../models/user'; +import { pack as packUser } from '../../../../../models/user'; import { publishUserListStream } from '../../../../../services/stream'; import define from '../../../define'; import { ApiError } from '../../../error'; diff --git a/src/server/api/endpoints/users/lists/push.ts b/src/server/api/endpoints/users/lists/push.ts index 6fdf55875d..c63bbb6ac0 100644 --- a/src/server/api/endpoints/users/lists/push.ts +++ b/src/server/api/endpoints/users/lists/push.ts @@ -1,7 +1,7 @@ import $ from 'cafy'; import ID, { transform } from '../../../../../misc/cafy-id'; import UserList from '../../../../../models/user-list'; -import User, { pack as packUser, isRemoteUser, fetchProxyAccount } from '../../../../../models/user'; +import { pack as packUser, isRemoteUser, fetchProxyAccount } from '../../../../../models/user'; import { publishUserListStream } from '../../../../../services/stream'; import { renderActivity } from '../../../../../remote/activitypub/renderer'; import renderFollow from '../../../../../remote/activitypub/renderer/follow'; diff --git a/src/server/api/endpoints/users/notes.ts b/src/server/api/endpoints/users/notes.ts index efa39da001..1c5882d5b2 100644 --- a/src/server/api/endpoints/users/notes.ts +++ b/src/server/api/endpoints/users/notes.ts @@ -1,7 +1,6 @@ import $ from 'cafy'; import ID, { transform } from '../../../../misc/cafy-id'; import Note, { packMany } from '../../../../models/note'; -import User from '../../../../models/user'; import define from '../../define'; import Following from '../../../../models/following'; import { ApiError } from '../../error';