fix: modal ui fixes, search and quote widget fix

This commit is contained in:
David Ralph
2021-11-10 16:20:40 +00:00
parent 62066fef05
commit 41750ff0e8
14 changed files with 63 additions and 38 deletions

View File

@@ -90,9 +90,9 @@ export default class Quote extends PureComponent {
}
// pick random
customQuote = customQuote[Math.floor(Math.random() * customQuote.length)];
customQuote = customQuote ? customQuote[Math.floor(Math.random() * customQuote.length)] : null;
if (customQuote !== '' && customQuote !== 'undefined' && customQuote !== ['']) {
if (customQuote && customQuote !== '' && customQuote !== 'undefined' && customQuote !== ['']) {
return this.setState({
quote: '"' + customQuote.quote + '"',
author: customQuote.author,

View File

@@ -114,7 +114,7 @@ export default class Search extends PureComponent {
autocompleteQuery,
autocompleteCallback,
microphone,
currentSearch: info.name
currentSearch: info ? info.name : 'Custom'
});
}