From ba3bd083ea64c8615e203f157e7bf9ca06395065 Mon Sep 17 00:00:00 2001 From: juniusfree <8164667+juniusfree@users.noreply.github.com> Date: Wed, 20 Mar 2024 21:22:46 +0800 Subject: [PATCH] Refactor naming --- .../src/components/Settings/CustomizeBanners/index.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/wondrous-bot-admin/src/components/Settings/CustomizeBanners/index.tsx b/wondrous-bot-admin/src/components/Settings/CustomizeBanners/index.tsx index 0b0d1e07b..ff2335b7a 100644 --- a/wondrous-bot-admin/src/components/Settings/CustomizeBanners/index.tsx +++ b/wondrous-bot-admin/src/components/Settings/CustomizeBanners/index.tsx @@ -191,7 +191,7 @@ const CommandBanner = ({ }); }; - const handleImageReplace = async ({ file, replaceImageCallback }) => { + const handleOnSave = async ({ file, replaceImageCallback }) => { if (!file) { handleResetAvatarImage(); return; @@ -211,7 +211,7 @@ const CommandBanner = ({ openSelectFile: () => bannerImageInputField.current.click(), imageType: AVATAR_EDITOR_TYPES.BANNER_IMAGE, onSave: async (file: File) => - handleImageReplace({ + handleOnSave({ file, replaceImageCallback: async () => await handleReplaceImage({ file, purpose: banner.purpose, imageInputField: bannerImageInputField }), @@ -236,7 +236,7 @@ const CommandBanner = ({ openSelectFile: () => topImageInputField.current.click(), imageType: AVATAR_EDITOR_TYPES.BANNER_LOGO_IMAGE, onSave: async (file: File) => - handleImageReplace({ + handleOnSave({ file, replaceImageCallback: async () => await handleReplaceImage({ file, purpose: logo.purpose, imageInputField: topImageInputField }),