Skip to content

Commit

Permalink
empty identifiers and aliases logic updated
Browse files Browse the repository at this point in the history
  • Loading branch information
insane-22 committed Jan 16, 2024
1 parent 1a5773a commit 70d3644
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/client/entity-editor/alias-editor/reducer.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ function reducer(
return state.delete(payload);
case REMOVE_EMPTY_ALIASES:
return state.filterNot(alias =>
alias.get('name') === '' && alias.get('language') === null && alias.get('sortName') === '');
alias.get('name') === '');
// no default
}
return state;
Expand Down
2 changes: 1 addition & 1 deletion src/client/entity-editor/identifier-editor/reducer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ function reducer(
return state.delete(payload);
case REMOVE_EMPTY_IDENTIFIERS:
return state.filterNot(identifier =>
identifier.get('value') === '' && identifier.get('type') === null);
identifier.get('value') === '');
case ADD_OTHER_ISBN: {
const {rowId, value, type: typeId} = payload;
// search if given identifier already exists
Expand Down

0 comments on commit 70d3644

Please sign in to comment.