Skip to content

Commit 4bede38

Browse files
committed
Altered utils.filterpicker to put the table as the 1st argument
1 parent 9bc7e9c commit 4bede38

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

scripting/lua_utils.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1570,16 +1570,16 @@ static int shell_execute (lua_State *L)
15701570

15711571
int filterpicker (lua_State *L)
15721572
{
1573-
const char * filtertitle = luaL_optstring (L, 1, "Filter");
1573+
const char * filtertitle = luaL_optstring (L, 2, "Filter");
15741574
const char * initialfilter = luaL_optstring (L, 3, "");
15751575

15761576
if (strlen (filtertitle) > 100)
15771577
luaL_error (L, "title too long (max 100 characters)");
15781578

1579-
const int table = 2;
1579+
const int table = 1;
15801580

15811581
if (!lua_istable (L, table))
1582-
luaL_error (L, "must have table of choices as 2nd argument");
1582+
luaL_error (L, "must have table of choices as first argument");
15831583

15841584
CFunctionListDlg dlg;
15851585

0 commit comments

Comments
 (0)