Skip to content

Commit

Permalink
Revert "Fix"
Browse files Browse the repository at this point in the history
This reverts commit 9660d7a59b9cef79debc2358d27da46ae200c55b.
  • Loading branch information
vmonakhov committed Sep 30, 2023
1 parent b94cae9 commit 0129740
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/pages/CorpImport/Linker.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ function Linker({ blobs, state, onSelect, onDelete, onUpdateColumn, onToggleColu
);

const first = state.first();
const selected = first && first.get("id") ? first.get("id").join("/") : null;
const selected = first ? first.get("id").join("/") : null;

function onChange(event, data) {
onSelect(data.value.split("/").map(x => parseInt(x, 10)));
Expand Down
2 changes: 0 additions & 2 deletions src/pages/DictImport/ColumnMapper.js
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,6 @@ function Columns({ blob, spreads, fieldOptions, columnTypes, onSetColumnType })
const columns = blob.getIn(["additional_metadata", "starling_fields"]);
const values = blob.get("values");

if (!columns) return null;

return (
<div className="blob">
<b className="blob-name">{blob.get("name")}</b>
Expand Down
4 changes: 1 addition & 3 deletions src/pages/DictImport/Linker.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,6 @@ function Columns({ blob, spreads, linkOptions, onUpdateColumn, onToggleColumn, o
const columns = blob.getIn(["additional_metadata", "starling_fields"]);
const values = blob.get("values");

if (!columns) return null;

return (
<div className="blob">
<Button negative icon="trash" size="tiny" onClick={() => onDelete(blob.get("id"))} />
Expand Down Expand Up @@ -119,7 +117,7 @@ function Linker({ blobs, state, spreads, onSelect, onDelete, onUpdateColumn, onT

const first = state.first();

const selected = first && first.get("id") ? first.get("id").join("/") : null;
const selected = first ? first.get("id").join("/") : null;

function onChange(event, data) {
onSelect(data.value.split("/").map(x => parseInt(x, 10)));
Expand Down

0 comments on commit 0129740

Please sign in to comment.