From 4b42c03fb9d04c58a917e4aa9267cc73fbb4fb6b Mon Sep 17 00:00:00 2001 From: yassinedorbozgithub Date: Mon, 2 Jun 2025 07:17:25 +0100 Subject: [PATCH] feat(api): add strict Setting types to channels --- api/src/channel/types.ts | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/api/src/channel/types.ts b/api/src/channel/types.ts index 0c654f19..7269a38c 100644 --- a/api/src/channel/types.ts +++ b/api/src/channel/types.ts @@ -6,14 +6,14 @@ * 2. All derivative works must include clear attribution to the original creator and software, Hexastack and Hexabot, in a prominent location (e.g., in the software's "About" section, documentation, and README file). */ -import { SettingCreateDto } from '@/setting/dto/setting.dto'; +import { AnySetting, StrictSetting } from '@/setting/schemas/types'; import { HyphenToUnderscore } from '@/utils/types/extension'; export type ChannelName = `${string}-channel`; -export type ChannelSetting = Omit< - SettingCreateDto, - 'group' | 'weight' -> & { - group: HyphenToUnderscore; -}; +export type ChannelSetting = StrictSetting< + AnySetting, + { + group: HyphenToUnderscore; + } +>;