Skip to content

Commit

Permalink
fix: changed let to const to fix eslint error
Browse files Browse the repository at this point in the history
  • Loading branch information
dhruvanshus-crest committed May 18, 2021
1 parent c736188 commit 65ba327
Showing 1 changed file with 11 additions and 10 deletions.
21 changes: 11 additions & 10 deletions ui/src/main/webapp/components/ControlWrapper.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,10 @@ class ControlWrapper extends React.PureComponent {
render() {
const { field, options, type, label, tooltip, help, encrypted = false } = this.props.entity;
const { handleChange, addCustomValidator, utilCustomFunctions } = this.props.utilityFuncts;
// We have to put empty object because markDownMessage prop can be undefined
// We have to put empty object because markDownMessage prop can be undefined
// because we are not explicitly setting it but expecting it from custom hooks only.
const { text, link, color, markdownType, token, linkText } = this.props.markdownMessage || {};
const { text, link, color, markdownType, token, linkText } =
this.props.markdownMessage || {};
let rowView;
if (this.props.entity.type === 'custom') {
const data = {
Expand Down Expand Up @@ -78,19 +79,19 @@ class ControlWrapper extends React.PureComponent {
: `No View Found for ${type} type`;
}

let helpText = (
const helpText = (
<>
<MarkdownMessage
text={ text || '' }
link={ link || '' }
color={ color || ''}
markdownType={ markdownType || '' }
token={ token || '' }
linkText={ linkText || '' }
text={text || ''}
link={link || ''}
color={color || ''}
markdownType={markdownType || ''}
token={token || ''}
linkText={linkText || ''}
/>
{help}
</>
)
);

return (
this.props.display && (
Expand Down

0 comments on commit 65ba327

Please sign in to comment.