From 456f87a4eeb4cda062623b34f7c67ed95d5c3a93 Mon Sep 17 00:00:00 2001 From: Fang-Pen Lin Date: Fri, 24 Oct 2025 12:15:14 -0700 Subject: [PATCH] Fix backend linter issue as well --- .../mysql/mysql-resource-schemas.ts | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) diff --git a/backend/src/ee/services/pam-resource/mysql/mysql-resource-schemas.ts b/backend/src/ee/services/pam-resource/mysql/mysql-resource-schemas.ts index 91ffa61ea..c87aa019a 100644 --- a/backend/src/ee/services/pam-resource/mysql/mysql-resource-schemas.ts +++ b/backend/src/ee/services/pam-resource/mysql/mysql-resource-schemas.ts @@ -58,19 +58,14 @@ export const MySQLAccountSchema = BasePamAccountSchema.extend({ credentials: MySQLAccountCredentialsSchema }); -export const CreateMySQLAccountSchema = BaseCreatePamAccountSchema.omit({ - // We don't support pwd rotation for mysql yet - rotationEnabled: true, - rotationIntervalSeconds: true -}).extend({ - credentials: MySQLAccountCredentialsSchema +export const CreateMySQLAccountSchema = BaseCreatePamAccountSchema.extend({ + credentials: MySQLAccountCredentialsSchema, + //We don't support pwd rotation for mysql yet + rotationEnabled: z.boolean().optional(), + rotationIntervalSeconds: z.number().optional() }); -export const UpdateMySQLAccountSchema = BaseUpdatePamAccountSchema.omit({ - // We don't support pwd rotation for mysql yet - rotationEnabled: true, - rotationIntervalSeconds: true -}).extend({ +export const UpdateMySQLAccountSchema = BaseUpdatePamAccountSchema.extend({ credentials: MySQLAccountCredentialsSchema.optional() });