Skip to content

Commit

Permalink
Drop store dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
starsep committed Jan 9, 2024
1 parent 36f8c44 commit fa2d58f
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 20 deletions.
16 changes: 0 additions & 16 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
"react-i18next": "^14.0.0",
"react-image-gallery": "^1.3.0",
"react-select": "^5.8.0",
"store": "^2.0.12",
"typescript": "^5.3.3"
},
"engines": {
Expand Down Expand Up @@ -60,7 +59,6 @@
"@types/react": "^18.2.45",
"@types/react-dom": "^18.2.18",
"@types/react-image-gallery": "^1.2.4",
"@types/store": "^2.0.5",
"@vitejs/plugin-react": "^4.2.1",
"@vitest/coverage-v8": "^1.1.0",
"sass": "^1.69.5",
Expand Down
3 changes: 1 addition & 2 deletions src/components/sidebar/photoUploader.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import Icon from "@mdi/react";
import React, { FC, useState } from "react";
import { Button, Card, Image } from "react-bulma-components";
import { useTranslation } from "react-i18next";
import store from "store";
import { useAppContext } from "~/appContext";
import { backendBaseUrl } from "~/backend";
import { DefibrillatorData } from "~/model/defibrillatorData";
Expand Down Expand Up @@ -97,7 +96,7 @@ const PhotoUpload: FC<DefibrillatorDetailsProps> = (props) => {

const url = auth?.options().url;
const storageKey = `${url}oauth2_access_token`;
const oauth2AccessToken = store.get(storageKey);
const oauth2AccessToken = localStorage.getItem(storageKey);
if (!oauth2AccessToken || !auth || !auth.authenticated()) {
const errorMessage =
`auth.authenticated()=${auth?.authenticated()} ` +
Expand Down

0 comments on commit fa2d58f

Please sign in to comment.