refactor: migration tag repository to kysely (#16398)

This commit is contained in:
Jason Rasmussen
2025-03-03 13:41:19 -05:00
committed by GitHub
parent ff19502035
commit d1fd0076cc
12 changed files with 343 additions and 245 deletions
+2 -1
View File
@@ -1,6 +1,7 @@
import { ApiProperty } from '@nestjs/swagger';
import { IsHexColor, IsNotEmpty, IsString } from 'class-validator';
import { TagEntity } from 'src/entities/tag.entity';
import { TagItem } from 'src/types';
import { Optional, ValidateHexColor, ValidateUUID } from 'src/validation';
export class TagCreateDto {
@@ -51,7 +52,7 @@ export class TagResponseDto {
color?: string;
}
export function mapTag(entity: TagEntity): TagResponseDto {
export function mapTag(entity: TagItem | TagEntity): TagResponseDto {
return {
id: entity.id,
parentId: entity.parentId ?? undefined,