Skip to content

Commit

Permalink
sonar fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Vadim73i committed Apr 23, 2024
1 parent 65feece commit ca36814
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
2 changes: 1 addition & 1 deletion app/src/components/fields/dynamicFieldsSection/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ export const getFieldComponent = (field) => {

if (field.fieldType === MULTILINE_TEXT_TYPE) {
fieldType = MULTILINE_TEXT_TYPE;
} else if (field.fieldType === ARRAY_TYPE && field.definedValues && field.definedValues.length) {
} else if (field.fieldType === ARRAY_TYPE && field.definedValues?.length) {
fieldType = ARRAY_TYPE;
} else if (field.fieldType === DATE_TYPE || field.fieldType.toLowerCase() === 'datetime') {
fieldType = DATE_TYPE;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -259,13 +259,7 @@ export class InviteUserModal extends Component {
};
formatUser = (user) => (user && { value: user.userLogin, label: user.userLogin }) || null;

filterProject = (value) =>
!(
value &&
this.props.selectedUser &&
this.props.selectedUser.assignedProjects &&
this.props.selectedUser.assignedProjects[value]
);
filterProject = (value) => !(value && this.props.selectedUser?.assignedProjects?.[value]);

render() {
const {
Expand Down

0 comments on commit ca36814

Please sign in to comment.