lualoader: Correct test and name

The functionality was correct, but our style guidelines tend to request that
we shy away from using boolean operations in place of explicit comparisons
to nil.
This commit is contained in:
Kyle Evans 2018-02-24 03:43:10 +00:00
parent e83d7bf208
commit 483f0a33f3
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=329899

View File

@ -130,11 +130,11 @@ local function check_nextboot()
return
end
local function check_nextboot_disabled(text)
return not text:match("^nextboot_enable=\"NO\"")
local function check_nextboot_enabled(text)
return text:match("^nextboot_enable=\"NO\"") == nil
end
if not config.parse(nextboot_file, true, check_nextboot_disabled) then
if not config.parse(nextboot_file, true, check_nextboot_enabled) then
-- This only fails if it actually hit a parse error
print("Failed to parse nextboot configuration: '" ..
nextboot_file .. "'")