refactor: centralize domain values and enforce numeric lint
This commit is contained in:
@@ -1,11 +1,13 @@
|
||||
import { ApiProperty } from '@nestjs/swagger';
|
||||
import { IsNotEmpty, IsString, MaxLength } from 'class-validator';
|
||||
|
||||
const MAX_TOKEN_LENGTH = 4096;
|
||||
|
||||
export class PutTbankConnectionDto {
|
||||
@ApiProperty({ writeOnly: true })
|
||||
@IsString()
|
||||
@IsNotEmpty()
|
||||
@MaxLength(4096)
|
||||
@MaxLength(MAX_TOKEN_LENGTH)
|
||||
declare token: string;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user