Merge pull request #81 from markuspeloquin/master

Fix crash when loading a custom colorscheme
This commit is contained in:
xxxserxxx 2020-04-16 08:38:38 -05:00 committed by GitHub
commit 84ec9e4e7a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -18,14 +18,11 @@ func init() {
}
func FromName(confDir configdir.ConfigDir, c string) (Colorscheme, error) {
cs, ok := registry[c]
if !ok {
cs, err := getCustomColorscheme(confDir, c)
if err != nil {
return cs, err
}
if cs, ok := registry[c]; ok {
return cs, nil
}
return cs, nil
cs, err := getCustomColorscheme(confDir, c)
return cs, err
}
func register(name string, c Colorscheme) {