forked from CIT/Vmeda.Online
		
	MOBILE-2744 ionic: Fix uncaught promises
This commit is contained in:
		
							parent
							
								
									82c8c5cdaf
								
							
						
					
					
						commit
						b39cbd338f
					
				| @ -61,7 +61,9 @@ export class AddonRemoteThemesProvider { | |||||||
|             hash: '' |             hash: '' | ||||||
|         }; |         }; | ||||||
| 
 | 
 | ||||||
|         return this.load(siteId, true); |         return this.load(siteId, true).catch((error) => { | ||||||
|  |             this.logger.error('Error loading site after site init', error); | ||||||
|  |         }); | ||||||
|     } |     } | ||||||
| 
 | 
 | ||||||
|     /** |     /** | ||||||
|  | |||||||
| @ -102,7 +102,9 @@ export class AddonRemoteThemesModule { | |||||||
| 
 | 
 | ||||||
|         // Load temporary styles when site config is checked in login.
 |         // Load temporary styles when site config is checked in login.
 | ||||||
|         eventsProvider.on(CoreEventsProvider.LOGIN_SITE_CHECKED, (data) => { |         eventsProvider.on(CoreEventsProvider.LOGIN_SITE_CHECKED, (data) => { | ||||||
|             remoteThemesProvider.loadTmpStyles(data.config.mobilecssurl); |             remoteThemesProvider.loadTmpStyles(data.config.mobilecssurl).catch((error) => { | ||||||
|  |                 logger.error('Error loading tmp styles', error); | ||||||
|  |             }); | ||||||
|         }); |         }); | ||||||
| 
 | 
 | ||||||
|         // Unload temporary styles when site config is "unchecked" in login.
 |         // Unload temporary styles when site config is "unchecked" in login.
 | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user