Fixes options view not loading (#213)
This commit is contained in:
committed by
GitHub
parent
ffe0666492
commit
b4105c76b1
@@ -54,6 +54,15 @@ export default function Options(): JSX.Element {
|
|||||||
trackSocialMedia: true,
|
trackSocialMedia: true,
|
||||||
whitelist: '',
|
whitelist: '',
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// Handle prod accounts with old social media stored as string
|
||||||
|
if (typeof items.socialMediaSites === 'string') {
|
||||||
|
await browser.storage.sync.set({
|
||||||
|
socialMediaSites: items.socialMediaSites.split('\n'),
|
||||||
|
});
|
||||||
|
items.socialMediaSites = items.socialMediaSites.split('\n');
|
||||||
|
}
|
||||||
|
|
||||||
setState({
|
setState({
|
||||||
...state,
|
...state,
|
||||||
apiKey: items.apiKey as string,
|
apiKey: items.apiKey as string,
|
||||||
|
|||||||
Reference in New Issue
Block a user