Skip to content

Commit

Permalink
75: remove unnecessary code
Browse files Browse the repository at this point in the history
  • Loading branch information
Kaloyan Marinov committed Sep 15, 2024
1 parent e3c871c commit a2ffaed
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 12 deletions.
9 changes: 0 additions & 9 deletions frontend/src/features/examples/OwnVocabTreasury.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ import { ActionFetchExamples, fetchExamples } from "./examplesSlice";
import { IActionAlertsCreate, alertsCreate } from "../alerts/alertsSlice";

interface LocationStateWithinOwnVocabTreasury {
fromRecordNewExample: null | boolean;
fromSingleExample: null | boolean;
fromEditExample: null | boolean;
}
Expand Down Expand Up @@ -54,14 +53,6 @@ export const OwnVocabTreasury = () => {

let location = useLocation<LocationStateWithinOwnVocabTreasury>();
let initialExamplesUrl: string;
// if (
// location.state &&
// location.state.fromRecordNewExample === true &&
// examplesLinks.last !== null
// ) {
// console.log(" from /example/new (i.e. <RecordNewExample>)");
// initialExamplesUrl = examplesLinks.last;
// } else if (
if (
location.state &&
location.state.fromSingleExample &&
Expand Down
3 changes: 0 additions & 3 deletions frontend/src/features/examples/RecordNewExample.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,6 @@ export const RecordNewExample = () => {

const locationDescriptor = {
pathname: "/own-vocabtreasury",
state: {
fromRecordNewExample: true,
},
};
history.push(locationDescriptor);
} catch (err) {
Expand Down

2 comments on commit a2ffaed

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

badge-test-coverage

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

badge-test-coverage

Please sign in to comment.