mirror of
https://github.com/BetterSEQTA/BetterSEQTA-Plus.git
synced 2026-06-06 03:34:40 +00:00
add closeThemeCreator error handling
This commit is contained in:
@@ -15,7 +15,6 @@ type ThemeContent = {
|
||||
};
|
||||
|
||||
export const StoreDownloadTheme = async (theme: { themeContent: Theme }) => {
|
||||
console.log(theme.themeContent.id);
|
||||
if (!theme.themeContent.id) return;
|
||||
|
||||
const themeContent = await fetch(`https://raw.githubusercontent.com/BetterSEQTA/BetterSEQTA-Themes/main/store/themes/${theme.themeContent.id}/theme.json`);
|
||||
|
||||
@@ -93,7 +93,12 @@ export class MessageHandler {
|
||||
return true;
|
||||
|
||||
case 'CloseThemeCreator':
|
||||
CloseThemeCreator();
|
||||
try {
|
||||
CloseThemeCreator();
|
||||
} catch (error) {
|
||||
console.error('Error closing theme creator:', error);
|
||||
sendResponse({ status: 'error' });
|
||||
}
|
||||
sendResponse({ status: 'success' });
|
||||
break;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user