mirror of
https://github.com/misskey-dev/misskey.git
synced 2024-12-27 21:10:20 +01:00
prohibit updating alsoKnownAs after moving
This commit is contained in:
parent
d3da4e56fb
commit
e94e702429
1 changed files with 10 additions and 1 deletions
|
@ -350,7 +350,6 @@ describe('Account Move', () => {
|
||||||
'/gallery/posts/like',
|
'/gallery/posts/like',
|
||||||
'/gallery/posts/unlike',
|
'/gallery/posts/unlike',
|
||||||
'/gallery/posts/update',
|
'/gallery/posts/update',
|
||||||
'/i/update',
|
|
||||||
'/i/move',
|
'/i/move',
|
||||||
'/notes/create',
|
'/notes/create',
|
||||||
'/notes/polls/vote',
|
'/notes/polls/vote',
|
||||||
|
@ -396,5 +395,15 @@ describe('Account Move', () => {
|
||||||
assert.strictEqual(res.body.error.code, 'YOUR_ACCOUNT_MOVED');
|
assert.strictEqual(res.body.error.code, 'YOUR_ACCOUNT_MOVED');
|
||||||
assert.strictEqual(res.body.error.id, '56f20ec9-fd06-4fa5-841b-edd6d7d4fa31');
|
assert.strictEqual(res.body.error.id, '56f20ec9-fd06-4fa5-841b-edd6d7d4fa31');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
test('Prohibit updating alsoKnownAs after moving', async () => {
|
||||||
|
const res = await api('/i/update', {
|
||||||
|
alsoKnownAs: [`@eve@${url.hostname}`],
|
||||||
|
}, alice);
|
||||||
|
|
||||||
|
assert.strictEqual(res.status, 403);
|
||||||
|
assert.strictEqual(res.body.error.code, 'YOUR_ACCOUNT_MOVED');
|
||||||
|
assert.strictEqual(res.body.error.id, '56f20ec9-fd06-4fa5-841b-edd6d7d4fa31');
|
||||||
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue