mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-09-22 13:39:35 +00:00
misc: added descriptive error message
This commit is contained in:
@@ -70,7 +70,7 @@ export const StoreProvider = ({ children }: { children: ReactNode }) => {
|
||||
|
||||
const useStoreContext = <T extends unknown>(selector: (state: SelectedEntriesState) => T): T => {
|
||||
const ctx = useContext(StoreContext);
|
||||
if (!ctx) throw new Error("Missing ");
|
||||
if (!ctx) throw new Error("Missing context provider");
|
||||
return useStore(ctx, selector);
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user