Skip to content

Commit

Permalink
fix(SystemsCVES): RHINENG-1872 - Remove obsolete Router (#1972)
Browse files Browse the repository at this point in the history
  • Loading branch information
bastilian authored Sep 12, 2023
1 parent b2bfa06 commit d00df21
Showing 1 changed file with 7 additions and 10 deletions.
17 changes: 7 additions & 10 deletions src/index.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import React, { useEffect, Fragment, useState } from 'react';
import { BrowserRouter as Router } from 'react-router-dom';
import SystemCVEs from './Components/SmartComponents/SystemCves/SystemCves';
import { SystemCvesStore } from './Store/Reducers/SystemCvesStore';
import PropTypes from 'prop-types';
Expand All @@ -21,15 +20,13 @@ const WrappedSystemCves = ({ getRegistry, ...props }) => {
setWrapper(() => getRegistry ? Provider : Fragment);
}, []);

return <Router>
{
Wrapper ? <Wrapper {...getRegistry && { store: getRegistry()?.getStore() }}>
<SystemCVEs canExport={canExport} canEditPairStatus={canEditPairStatus} {...props}/>
</Wrapper> : <Bullseye>
<Spinner size="xl" />
</Bullseye>
}
</Router>;
return (
Wrapper ? <Wrapper {...getRegistry && { store: getRegistry()?.getStore() }}>
<SystemCVEs canExport={canExport} canEditPairStatus={canEditPairStatus} {...props} />
</Wrapper> : <Bullseye>
<Spinner size="xl" />
</Bullseye>
);
};

WrappedSystemCves.propTypes = {
Expand Down

0 comments on commit d00df21

Please sign in to comment.