Skip to content

Commit

Permalink
fix: handled warnings and updated the changes
Browse files Browse the repository at this point in the history
  • Loading branch information
dhruvanshus-crest committed May 18, 2021
1 parent 85030c3 commit c8240d5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion ui/src/main/webapp/components/TextComponent.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class TextComponent extends Component {
placeholder={this.props?.controlOptions?.placeholder}
className={this.props.field}
disabled={this.props.disabled}
value={this.props.value === null ? '' : this.props.value.toString()}
value={this.props.value === null || typeof this.props.value === 'undefined' ? '' : this.props.value.toString()}
onChange={this.handleChange}
type={this.props.encrypted ? 'password' : 'text'}
/>
Expand Down
2 changes: 1 addition & 1 deletion ui/src/main/webapp/util/messageUtil.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export const parseErrorMsg = (err) => {
let matches;
try {
const msg = err.response.data.messages[0].text;
regex = /.+"REST Error \[[\d]+\]:\s+.+\s+--\s+(?:b'([\s\S]*)'|([\s\S]*))"\.\s*See splunkd\.log(\/python.log)? for more details\./;
regex = /.+"REST Error \[[\d]+\]:\s+.+\s+--\s+([\s\S]*)"\.\s*See splunkd\.log(\/python.log)? for more details\./;
matches = regex.exec(msg);
if (matches && matches[1]) {
try {
Expand Down

0 comments on commit c8240d5

Please sign in to comment.