mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Fix whitelist string -> array error in checkPbo
Fix #2913 Use splitString instead of call compile to convert string into an array
This commit is contained in:
parent
c928a0d6cb
commit
91ace4fc9b
@ -167,7 +167,7 @@ call FUNC(checkFiles);
|
|||||||
[
|
[
|
||||||
GVAR(checkPBOsAction),
|
GVAR(checkPBOsAction),
|
||||||
GVAR(checkPBOsCheckAll),
|
GVAR(checkPBOsCheckAll),
|
||||||
call compile GVAR(checkPBOsWhitelist)
|
GVAR(checkPBOsWhitelist)
|
||||||
] call FUNC(checkPBOs)
|
] call FUNC(checkPBOs)
|
||||||
}] call FUNC(addEventHandler);
|
}] call FUNC(addEventHandler);
|
||||||
|
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
* 1 = Warn permanently
|
* 1 = Warn permanently
|
||||||
* 2 = Kick
|
* 2 = Kick
|
||||||
* 1: Check all PBOs? (default: false) <BOOL>
|
* 1: Check all PBOs? (default: false) <BOOL>
|
||||||
* 2: Whitelist (default: "[]") <STRING>
|
* 2: Whitelist (default: "") <STRING>
|
||||||
*
|
*
|
||||||
* Return Value:
|
* Return Value:
|
||||||
* None
|
* None
|
||||||
@ -18,9 +18,13 @@
|
|||||||
*/
|
*/
|
||||||
#include "script_component.hpp"
|
#include "script_component.hpp"
|
||||||
|
|
||||||
params ["_mode", ["_checkAll", false], ["_whitelist", "[]"]];
|
params ["_mode", ["_checkAll", false], ["_whitelist", "", [""]]];
|
||||||
|
TRACE_3("params",_mode,_checkAll,_whitelist);
|
||||||
|
|
||||||
_whitelist = [_whitelist, {toLower _this}] call FUNC(map);
|
//lowercase and convert whiteList String into array of strings:
|
||||||
|
_whitelist = toLower _whitelist;
|
||||||
|
_whitelist = _whitelist splitString "[,""']";
|
||||||
|
TRACE_1("Array",_whitelist);
|
||||||
|
|
||||||
ACE_Version_CheckAll = _checkAll;
|
ACE_Version_CheckAll = _checkAll;
|
||||||
ACE_Version_Whitelist = _whitelist;
|
ACE_Version_Whitelist = _whitelist;
|
||||||
|
Loading…
Reference in New Issue
Block a user