feat(cli): move user and guild registration from API to local CLI
This commit is contained in:
@@ -33,11 +33,6 @@ export class CenterApiKeyGuard implements CanActivate {
|
||||
return true;
|
||||
}
|
||||
|
||||
// only guild registration is exempt from API key; it is protected by HMAC secret
|
||||
if (method === 'POST' && (path === '/nodes/register' || path.endsWith('/nodes/register'))) {
|
||||
return true;
|
||||
}
|
||||
|
||||
const received = req.headers['x-api-key'];
|
||||
const apiKey = Array.isArray(received) ? received[0] : received;
|
||||
if (!apiKey) throw new UnauthorizedException('missing api key');
|
||||
|
||||
Reference in New Issue
Block a user