SharedPreferences: fixes so UI Theme can be set back to Default (#24628)

This commit is contained in:
Agnès Toulet
2020-05-13 15:08:49 +02:00
committed by GitHub
parent c1b057a57d
commit cd9cbe5e16

View File

@@ -100,7 +100,7 @@ export class SharedPreferences extends PureComponent<Props, State> {
};
onThemeChanged = (theme: SelectableValue<string>) => {
if (!theme || !theme.value) {
if (!theme || typeof theme.value !== 'string') {
return;
}
this.setState({ theme: theme.value });