16672: Rearranges code related to getting current process' UUID.
[arvados-workbench2.git] / src / store / process-logs-panel / process-logs-panel.ts
index 87b50bd2f97ff89f1a7d057e580aa3093a13bf80..74a18041bcc9e07f9f28000c8ab10588f6be0e50 100644 (file)
@@ -2,8 +2,8 @@
 //
 // SPDX-License-Identifier: AGPL-3.0
 
-import { RootState } from '../store';
 import { matchProcessLogRoute, matchProcessRoute } from 'routes/routes';
+import { RouterState } from 'react-router-redux';
 
 export interface ProcessLogsPanel {
     filters: string[];
@@ -19,7 +19,7 @@ export const getProcessPanelLogs = ({ selectedFilter, logs }: ProcessLogsPanel)
     return logs[selectedFilter];
 };
 
-export const getProcessLogsPanelCurrentUuid = ({ router }: RootState) => {
+export const getProcessLogsPanelCurrentUuid = (router: RouterState) => {
     const pathname = router.location ? router.location.pathname : '';
     const match = matchProcessLogRoute(pathname) || matchProcessRoute(pathname);
     return match ? match.params.id : undefined;