aboutsummaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'plugins')
-rw-r--r--plugins/select_colorscheme.lua8
1 files changed, 5 insertions, 3 deletions
diff --git a/plugins/select_colorscheme.lua b/plugins/select_colorscheme.lua
index f20d949..1e25bc4 100644
--- a/plugins/select_colorscheme.lua
+++ b/plugins/select_colorscheme.lua
@@ -61,7 +61,7 @@ function Settings:get_color_scheme()
end
local function make_color_module_name(name)
- return (name == color_default.name) and color_default.module or "colors."..name
+ return (name == color_default.name) and color_default.module or "colors."..name
end
function Settings:change_color(name)
@@ -83,8 +83,10 @@ function Settings:load_settings()
local fp = io.open(PATH_CONFIG, "r")
if fp then
local name = fp:read("*a")
- core.reload_module(make_color_module_name(name))
- Settings.color_scheme = name
+ if name and name ~= "" then
+ core.reload_module(make_color_module_name(name))
+ Settings.color_scheme = name
+ end
fp:close()
end
end