mirror of
https://github.com/directus/directus.git
synced 2026-01-23 19:18:07 -05:00
Add invalid IP exception
This commit is contained in:
@@ -3,6 +3,7 @@ export * from './failed-validation';
|
||||
export * from './forbidden';
|
||||
export * from './hit-rate-limit';
|
||||
export * from './invalid-credentials';
|
||||
export * from './invalid-ip';
|
||||
export * from './invalid-otp';
|
||||
export * from './invalid-payload';
|
||||
export * from './invalid-query';
|
||||
|
||||
7
api/src/exceptions/invalid-ip.ts
Normal file
7
api/src/exceptions/invalid-ip.ts
Normal file
@@ -0,0 +1,7 @@
|
||||
import { BaseException } from './base';
|
||||
|
||||
export class InvalidIPException extends BaseException {
|
||||
constructor(message = 'Invalid IP address.') {
|
||||
super(message, 401, 'INVALID_IP');
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user