1
0
Fork 1
mirror of https://example.com synced 2024-11-22 11:16:38 +09:00

feat: allow admins to migrate accounts

This commit is contained in:
naskya 2023-10-17 04:54:31 +09:00
parent 50cf8d162e
commit a0bbaa7fb7
Signed by: naskya
GPG key ID: 164DFF24E2D40139
2 changed files with 1 additions and 6 deletions

View file

@ -40,6 +40,7 @@
## 細かい変更点
- 管理者アカウントも引っ越しできるように
- まだマージされていない本家 Firefish へのマージリクエストを独断で取り込み
- アイコンフォントのスタイルを設定から選べるように ([MR](https://git.joinfirefish.org/firefish/firefish/-/merge_requests/10613))
- デフォルトのアイコンの太さも細めに変更

View file

@ -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);