mirror of
https://github.com/atom/atom.git
synced 2026-04-28 03:01:47 -04:00
Log a warning when a theme fails to load
Previously Atom would fail to launch if a theme referenced in the config was not found.
This commit is contained in:
@@ -27,7 +27,11 @@ class ThemeManager
|
||||
@loadTheme(themeName) for themeName in themeNames
|
||||
@loadUserStylesheet()
|
||||
|
||||
loadTheme: (name) -> @loadedThemes.push(new Theme(name))
|
||||
loadTheme: (name) ->
|
||||
try
|
||||
@loadedThemes.push(new Theme(name))
|
||||
catch error
|
||||
console.warn("Failed to load theme #{name}", error.stack ? error)
|
||||
|
||||
getUserStylesheetPath: ->
|
||||
stylesheetPath = fsUtils.resolve(path.join(config.configDirPath, 'user'), ['css', 'less'])
|
||||
|
||||
Reference in New Issue
Block a user