Store hotlink access token hash on upload for short URL lookup.
This commit is contained in:
@@ -1,8 +1,13 @@
|
||||
import { IsNotEmpty, IsString } from 'class-validator';
|
||||
import { IsHash, IsNotEmpty, IsString } from 'class-validator';
|
||||
import { IsImageMimeType } from '../../../validation/decorators/isImageMimeType';
|
||||
import { UploadCiphertextOptionsDto } from './UploadCiphertextOptionsDto';
|
||||
|
||||
export class CreateHotlinkUploadDto extends UploadCiphertextOptionsDto {
|
||||
@IsNotEmpty()
|
||||
@IsString()
|
||||
@IsHash('sha256')
|
||||
accessTokenHash: string;
|
||||
|
||||
@IsNotEmpty()
|
||||
@IsString()
|
||||
@IsImageMimeType()
|
||||
|
||||
Reference in New Issue
Block a user