feat: allow admins to migrate accounts
This commit is contained in:
parent
50cf8d162e
commit
a0bbaa7fb7
2 changed files with 1 additions and 6 deletions
|
@ -40,6 +40,7 @@
|
|||
|
||||
## 細かい変更点
|
||||
|
||||
- 管理者アカウントも引っ越しできるように
|
||||
- まだマージされていない本家 Firefish へのマージリクエストを独断で取り込み
|
||||
- アイコンフォントのスタイルを設定から選べるように ([MR](https://git.joinfirefish.org/firefish/firefish/-/merge_requests/10613))
|
||||
- デフォルトのアイコンの太さも細めに変更
|
||||
|
|
|
@ -42,11 +42,6 @@ export const meta = {
|
|||
code: "NOT_REMOTE",
|
||||
id: "4362f8dc-731f-4ad8-a694-be2a88922a24",
|
||||
},
|
||||
adminForbidden: {
|
||||
message: "Admins cant migrate.",
|
||||
code: "NOT_ADMIN_FORBIDDEN",
|
||||
id: "4362e8dc-731f-4ad8-a694-be2a88922a24",
|
||||
},
|
||||
noSuchUser: {
|
||||
message: "No such user.",
|
||||
code: "NO_SUCH_USER",
|
||||
|
@ -92,7 +87,6 @@ function moveActivity(toUrl: string, fromUrl: string) {
|
|||
|
||||
export default define(meta, paramDef, async (ps, user) => {
|
||||
if (!ps.moveToAccount) throw new ApiError(meta.errors.noSuchMoveTarget);
|
||||
if (user.isAdmin) throw new ApiError(meta.errors.adminForbidden);
|
||||
if (user.movedToUri) throw new ApiError(meta.errors.alreadyMoved);
|
||||
|
||||
const { username, host } = parse(ps.moveToAccount);
|
||||
|
|
Loading…
Reference in a new issue