diff --git a/addons/org/functions/fnc_initOrgStore.sqf b/addons/org/functions/fnc_initOrgStore.sqf index 6c15eea..a90f517 100644 --- a/addons/org/functions/fnc_initOrgStore.sqf +++ b/addons/org/functions/fnc_initOrgStore.sqf @@ -14,7 +14,7 @@ * Organization interface */ -private _orgStoreInterface = createHashMapObject [[ +private _orgStoreDeclaration = [ ["#type", "IOrganizationStore"], ["#create", { private _store = GETMVAR(FORGE_STORE_REG,nil); @@ -103,7 +103,7 @@ private _orgStoreInterface = createHashMapObject [[ private _store = GETMVAR(FORGE_STORE_REG,nil); private _org = _store call ["get", ["organizations", _key]] - if (isNil "_org") exitWith { ERROR_MSG_1("Organization with composite key %1 not found", _key); nil }; + if (isNil "_org") exitWith { ERROR_MSG_1("Organization with composite key %1 not found",_key); nil }; _org }], @@ -117,7 +117,7 @@ private _orgStoreInterface = createHashMapObject [[ _store call ["delete", ["organizationNameIndex", _key]]; - if (isNil "_key") exitWith { ERROR_MSG_1("Key for organization not found", _key); false }; + if (isNil "_key") exitWith { ERROR_MSG_1("Key for organization not found",_key); false }; _store call ["delete", ["organizations", _key]]; @@ -128,7 +128,8 @@ private _orgStoreInterface = createHashMapObject [[ true }] -]]; +]; +private _orgStoreInterface = createHashMapObject [_orgStoreDeclaration]; SETMVAR(FORGE_ORG_STORE_REG,_orgStoreInterface); GETMVAR(FORGE_ORG_STORE_REG,nil) \ No newline at end of file diff --git a/addons/org/functions/fnc_leave.sqf b/addons/org/functions/fnc_leave.sqf index 1f6a532..8648b59 100644 --- a/addons/org/functions/fnc_leave.sqf +++ b/addons/org/functions/fnc_leave.sqf @@ -28,7 +28,7 @@ private _org = _store call ["getByKey", [_key]]; private _timestamp = systemTimeUTC apply { if (_x < 10) then { "0" + str _x } else { str _x }}; private _dateTime = format ["%1-%2-%3_%4:%5:%6.%7", _timestamp#0, _timestamp#1, _timestamp#2, _timestamp#3, _timestamp#4, _timestamp#5, _timestamp#6]; -if (isNil "_org") exitWith { TRACE_1("Organization not found", _key); false }; +if (isNil "_org") exitWith { TRACE_1("Organization not found",_key); false }; private _members = _org get "members"; private _logs = _org get "logs";