fix: shared check for server setup availability (#30311)

* fix: shared check for server setup availability

* chore: add medium test

* feat: require @Authenticated decorator everywhere

* fix: lints
This commit is contained in:
bo0tzz 2026-07-30 21:12:25 +02:00 committed by GitHub
parent 1f16fe16c2
commit a316ba35ca
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
24 changed files with 249 additions and 66 deletions

View file

@ -38,9 +38,6 @@ export const errorDto = {
incorrectLogin: {
message: 'Incorrect email or password',
},
alreadyHasAdmin: {
message: 'The server already has an admin',
},
};
export const signupResponseDto = {

View file

@ -108,7 +108,7 @@ describe('/admin/database-backups', () => {
const { status, body } = await request(app).post('/admin/database-backups/start-restore').send();
expect(status).toBe(400);
expect(body).toEqual(errorDto.badRequest('The server already has an admin'));
expect(body).toEqual(errorDto.badRequest('Admin setup is not available'));
});
it.sequential('should enter maintenance mode in "database restore mode"', async () => {