From de6f9183fd0ea2706f7dffbb3c0c2bac029c0a44 Mon Sep 17 00:00:00 2001 From: lethosor Date: Fri, 29 Jan 2021 00:02:42 -0500 Subject: [PATCH] Fix changelog, replace a couple qerror calls with error Ref #1746 --- docs/changelog.txt | 2 +- library/lua/utils.lua | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/changelog.txt b/docs/changelog.txt index 771be6ac3..64c57495d 100644 --- a/docs/changelog.txt +++ b/docs/changelog.txt @@ -45,7 +45,7 @@ changelog.txt uses a syntax similar to RST, with a few special sequences: - `quickfort`: Dreamfort blueprint set improvements: add a streamlined checklist for all required dreamfort commands and give names to stockpiles, levers, bridges, and zones ## Lua -- ``processArgs2()`` added to utils.lua, providing a callback interface for parameter parsing and getopt-like flexibility for parameter ordering and combination (see docs in ``library/lua/utils.lua`` and ``library/lua/3rdparty/alt_getopt.lua`` for details). +- ``processArgsGetopt()`` added to utils.lua, providing a callback interface for parameter parsing and getopt-like flexibility for parameter ordering and combination (see docs in ``library/lua/utils.lua`` and ``library/lua/3rdparty/alt_getopt.lua`` for details). # 0.47.04-r4 diff --git a/library/lua/utils.lua b/library/lua/utils.lua index c652e54d4..c85560265 100644 --- a/library/lua/utils.lua +++ b/library/lua/utils.lua @@ -647,10 +647,10 @@ function processArgsGetopt(args, optionActions) for _,optionAction in ipairs(optionActions) do local sh_opt,long_opt = optionAction[1], optionAction[2] if not sh_opt or type(sh_opt) ~= 'string' or #sh_opt ~= 1 then - qerror('optionAction missing option letter at index 1') + error('optionAction missing option letter at index 1') end if not optionAction.handler then - qerror(string.format('handler missing for option "%s"', sh_opt)) + error(string.format('handler missing for option "%s"', sh_opt)) end sh_opts = sh_opts .. sh_opt if optionAction.hasArg then sh_opts = sh_opts .. ':' end