Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
ibolton336 committed Sep 29, 2023
1 parent e1614ae commit 4ac04e6
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 9 deletions.
1 change: 0 additions & 1 deletion client/src/app/components/KeycloakProvider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ export const KeycloakProvider: React.FC<IKeycloakProviderProps> = ({
initInterceptors(
() =>
new Promise<string>((resolve, reject) => {
console.log("intercept request!", keycloak);
if (keycloak.token) {
if (keycloak.refreshToken) {
keycloak
Expand Down
9 changes: 1 addition & 8 deletions client/src/app/components/TargetCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -68,14 +68,8 @@ export const TargetCard: React.FC<TargetCardProps> = ({
}) => {
const { t } = useTranslation();
const [isCardSelected, setCardSelected] = React.useState(cardSelected);
const [imageDataUrl, setImageDataUrl] = React.useState<string | null>(null);

React.useEffect(() => {
const imagePath = target?.image?.id
? `/hub/files/${target?.image.id}`
: DefaultRulesetIcon;
fetchImageAndSetDataUrl(imagePath);
}, [target]);
const [imageDataUrl, setImageDataUrl] = React.useState<string | null>(null);

const prevSelectedLabel =
formLabels?.find((formLabel) => {
Expand Down Expand Up @@ -127,7 +121,6 @@ export const TargetCard: React.FC<TargetCardProps> = ({
console.error("There was an issue fetching the image:", error);
}
};

const imagePath = target?.image?.id
? `/hub/files/${target?.image.id}`
: DefaultRulesetIcon;
Expand Down

0 comments on commit 4ac04e6

Please sign in to comment.