Skip to content

Commit 7d3cb7a

Browse files
committed
#462 set Lua.telemetry.enable default to nil
1 parent 1dbf4ed commit 7d3cb7a

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

script/config.lua

+8-1
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,13 @@ local function String(v)
2222
return true, tostring(v)
2323
end
2424

25+
local function Nil(v)
26+
if type(v) == 'nil' then
27+
return true, nil
28+
end
29+
return false
30+
end
31+
2532
local function Str2Hash(sep)
2633
return function (v)
2734
if type(v) == 'string' then
@@ -186,7 +193,7 @@ local ConfigTemplate = {
186193
progressBar = {true, Boolean},
187194
},
188195
telemetry = {
189-
enable = {true, Boolean},
196+
enable = {nil, Or(Boolean, Nil)},
190197
}
191198
}
192199

0 commit comments

Comments
 (0)