Skip to content

Commit

Permalink
Fixed an issue when trying to print help for a nil default option value.
Browse files Browse the repository at this point in the history
  • Loading branch information
cjtallman committed Oct 26, 2015
1 parent b8c1414 commit e865746
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/cliargs.lua
Original file line number Diff line number Diff line change
Expand Up @@ -613,7 +613,7 @@ function cli:print_help(noprint)
end

if self.optargument.maxcount > 0 then
append(self.optargument.key, self.optargument.desc .. " (optional, default: " .. self.optargument.default .. ")")
append(self.optargument.key, self.optargument.desc .. " (optional, default: " .. tostring(self.optargument.default) .. ")")
end

if #self.optional > 0 then
Expand Down

0 comments on commit e865746

Please sign in to comment.