mirror of
https://github.com/hexastack/hexabot
synced 2025-02-23 12:59:14 +00:00
fix(frontend): remove unnecessary useMemo
This commit is contained in:
parent
5197e57efa
commit
33ce8cc5bf
@ -6,7 +6,7 @@
|
|||||||
* 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).
|
* 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 React, { useContext, useMemo } from "react";
|
import React, { useContext } from "react";
|
||||||
|
|
||||||
import { ConfirmDialog } from "@/app-components/dialogs";
|
import { ConfirmDialog } from "@/app-components/dialogs";
|
||||||
import { DialogsContext } from "@/contexts/dialogs.context";
|
import { DialogsContext } from "@/contexts/dialogs.context";
|
||||||
@ -50,12 +50,9 @@ export const useDialogs = (): DialogHook => {
|
|||||||
[open],
|
[open],
|
||||||
);
|
);
|
||||||
|
|
||||||
return useMemo(
|
return {
|
||||||
() => ({
|
|
||||||
open,
|
open,
|
||||||
close,
|
close,
|
||||||
confirm,
|
confirm,
|
||||||
}),
|
};
|
||||||
[close, open, confirm],
|
|
||||||
);
|
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user