Skip to content

Commit

Permalink
fix ts errors
Browse files Browse the repository at this point in the history
  • Loading branch information
molotgor committed Nov 18, 2024
1 parent db44b4e commit aec34ac
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/components/JSONViewer/NotebookParamsCell.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ const NotebookParamsCell = ({
const paramsWithType = Object.fromEntries(
paramsValue
.filter(filterParameters)
.map(({ name, type, value }) => [name, convertParameterValue(value, type)]),
.map(({ name, type: paramType, value }) => [name, convertParameterValue(value, paramType)]),
);
const res = await api.jsonViewer.launchNotebook(notebook.name, paramsWithType);
if (res.task_id !== '') {
Expand Down
6 changes: 3 additions & 3 deletions src/stores/JSONViewer/JSONViewerStore.ts
Original file line number Diff line number Diff line change
Expand Up @@ -394,9 +394,9 @@ export class JSONViewerStore {
const nextId = this.treeNodes[type].find(
node => node.displayTimestamp && node.displayTimestamp >= timestamp,
);
const prevId = this.treeNodes[type].findLast(
node => node.displayTimestamp && node.displayTimestamp <= timestamp,
);
const prevId = this.treeNodes[type]
.reverse()
.find(node => node.displayTimestamp && node.displayTimestamp <= timestamp);
return {
prevId: prevId ? prevId.id : '',
nextId: nextId ? nextId.id : '',
Expand Down

0 comments on commit aec34ac

Please sign in to comment.