Fixed LUA common library crashing when passing an empty status
This commit is contained in:
parent
599e441cc8
commit
3c752f7fe3
2 changed files with 2 additions and 2 deletions
|
@ -295,7 +295,7 @@ local function status_show(isWarning, text)
|
|||
status_line = 1
|
||||
status_isWarning = isWarning
|
||||
status_text = {}
|
||||
local textToParse = text or "???"
|
||||
local textToParse = (text and text ~= "") and text or "???"
|
||||
for line in string.gmatch(textToParse, "[^\n]+") do
|
||||
if line ~= "" then
|
||||
table.insert(status_text, line)
|
||||
|
|
|
@ -301,7 +301,7 @@ local function status_show(isWarning, text)
|
|||
status_line = 1
|
||||
status_isWarning = isWarning
|
||||
status_text = {}
|
||||
local textToParse = text or "???"
|
||||
local textToParse = (text and text ~= "") and text or "???"
|
||||
for line in string.gmatch(textToParse, "[^\n]+") do
|
||||
if line ~= "" then
|
||||
table.insert(status_text, line)
|
||||
|
|
Loading…
Reference in a new issue