Fixes issues with the API whitelist (#6865)

* Fixes issues with the API whitelist

* Update code/modules/world_api/api_command.dm

Co-Authored-By: Erki <skull132@users.noreply.github.com>
This commit is contained in:
Werner
2019-08-14 09:10:08 +02:00
committed by Erki
parent 726e8d13e6
commit 60073ab556
2 changed files with 1 additions and 2 deletions

View File

@@ -834,7 +834,6 @@ var/list/gamemode_cache = list()
if("api_rate_limit_whitelist")
config.api_rate_limit_whitelist = text2list(value, ";")
if("mc_ticklimit_init")
config.mc_init_tick_limit = text2num(value) || TICK_LIMIT_MC_INIT_DEFAULT

View File

@@ -66,7 +66,7 @@
log_debug("API: Throttling bypassed - Command [name] set to no_throttle")
return FALSE
if (config.api_rate_limit_whitelist[addr] == null)
if (config.api_rate_limit_whitelist[addr])
log_debug("API: Throttling bypassed - IP [addr] is whitelisted.")
return FALSE