Skip to content

Commit

Permalink
fix: linter about shadowed variables
Browse files Browse the repository at this point in the history
  • Loading branch information
jaybuidl committed Oct 7, 2023
1 parent a1c67ca commit f42cc14
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions web/src/components/CasesDisplay/Search.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,9 @@ const Search: React.FC = () => {
const { data: courtTreeData } = useCourtTree();
const items = useMemo(() => {
if (!isUndefined(courtTreeData)) {
const items = [rootCourtToItems(courtTreeData.court!, "id")];
items.push({ label: "All Courts", value: "all" });
return items;
const courts = [rootCourtToItems(courtTreeData.court!, "id")];
courts.push({ label: "All Courts", value: "all" });
return courts;
}
return undefined;
}, [courtTreeData]);
Expand Down
6 changes: 3 additions & 3 deletions web/src/context/IsListProvider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ const Context = createContext<IIsListProvider>({
const IsListProvider: React.FC<{ children?: React.ReactNode }> = ({ children }) => {
const [isListStorage, setIsListStorage] = useLocalStorage("isList", false);
const [isList, setIsListState] = useToggle(isListStorage ?? false);
const setIsList = (value: boolean) => {
setIsListState(value);
setIsListStorage(value);
const setIsList = (toggle: boolean) => {
setIsListState(toggle);
setIsListStorage(toggle);
};

const value = {
Expand Down

0 comments on commit f42cc14

Please sign in to comment.