mirror of
https://github.com/sqlchat/sqlchat.git
synced 2025-09-28 10:33:23 +08:00
refactor: rename method
This commit is contained in:
@ -169,7 +169,7 @@ const CreateConnectionModal = (props: Props) => {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
const handleCreateConnection = async () => {
|
const handleUpsertConnection = async () => {
|
||||||
if (isRequesting) {
|
if (isRequesting) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -416,7 +416,7 @@ const CreateConnectionModal = (props: Props) => {
|
|||||||
<button className="btn btn-outline" onClick={close}>
|
<button className="btn btn-outline" onClick={close}>
|
||||||
{t("common.close")}
|
{t("common.close")}
|
||||||
</button>
|
</button>
|
||||||
<button className="btn" disabled={isRequesting || !allowSave} onClick={handleCreateConnection}>
|
<button className="btn" disabled={isRequesting || !allowSave} onClick={handleUpsertConnection}>
|
||||||
{isRequesting && <Icon.BiLoaderAlt className="w-4 h-auto animate-spin mr-1" />}
|
{isRequesting && <Icon.BiLoaderAlt className="w-4 h-auto animate-spin mr-1" />}
|
||||||
{t("common.save")}
|
{t("common.save")}
|
||||||
</button>
|
</button>
|
||||||
|
Reference in New Issue
Block a user