Minor cleaning
This commit is contained in:
parent
b31e7a48ab
commit
84416b130b
2
init.lua
2
init.lua
|
@ -24,7 +24,7 @@ i3 = {
|
||||||
data = core.deserialize(storage:get_string"data") or {},
|
data = core.deserialize(storage:get_string"data") or {},
|
||||||
|
|
||||||
settings = {
|
settings = {
|
||||||
debug_mode = true,
|
debug_mode = false,
|
||||||
max_favs = 6,
|
max_favs = 6,
|
||||||
max_waypoints = 30,
|
max_waypoints = 30,
|
||||||
min_fs_version = 6,
|
min_fs_version = 6,
|
||||||
|
|
|
@ -205,7 +205,7 @@ function i3.remove_tab(name)
|
||||||
return err "i3.remove_tab: tab name missing"
|
return err "i3.remove_tab: tab name missing"
|
||||||
end
|
end
|
||||||
|
|
||||||
for i = #i3.tabs, 1, -1 do
|
for i = #i3.tabs, 2, -1 do
|
||||||
local def = i3.tabs[i]
|
local def = i3.tabs[i]
|
||||||
if def and name == def.name then
|
if def and name == def.name then
|
||||||
remove(i3.tabs, i)
|
remove(i3.tabs, i)
|
||||||
|
@ -448,11 +448,9 @@ end
|
||||||
function i3.remove_minitab(name)
|
function i3.remove_minitab(name)
|
||||||
if not true_str(name) then
|
if not true_str(name) then
|
||||||
return err "i3.remove_minitab: name missing"
|
return err "i3.remove_minitab: name missing"
|
||||||
elseif name == "all" then
|
|
||||||
return err "i3.remove_minitab: removing the 'All' tab is not allowed"
|
|
||||||
end
|
end
|
||||||
|
|
||||||
for i = #i3.minitabs, 1, -1 do
|
for i = #i3.minitabs, 2, -1 do
|
||||||
local v = i3.minitabs[i]
|
local v = i3.minitabs[i]
|
||||||
if v and v.name == name then
|
if v and v.name == name then
|
||||||
remove(i3.minitabs, i)
|
remove(i3.minitabs, i)
|
||||||
|
|
Ŝarĝante…
Reference in New Issue