Refactor ToastProvider and CabinetMaintenance to streamline showToast usage

This commit is contained in:
Md Asif 2024-12-21 20:57:30 +05:30
parent 2b940c3d43
commit 650a6dbdd0
2 changed files with 2 additions and 2 deletions

View File

@ -45,7 +45,7 @@ export const ToastProvider = ({ children }) => {
}
return (
<ToastContext.Provider value={{ showToast }}>
<ToastContext.Provider value={ showToast }>
{children}
{toast.show && (
<div

View File

@ -6,7 +6,7 @@ import { useToast } from "../hooks/useToast";
function CabinetMaintenace() {
const navigate = useNavigate();
const { showToast } = useToast();
const showToast = useToast();
const [operation, setOperation] = useState("");
const handleNext = () => {