Eased fetch ratelimit

This commit is contained in:
Jeremy Zhang 2017-04-11 00:34:21 +00:00
parent b791853562
commit 0e204bdecc
2 changed files with 2 additions and 2 deletions

View File

@ -225,7 +225,7 @@ def get_online_embed_users(guild_id):
@api.route("/fetch", methods=["GET"]) @api.route("/fetch", methods=["GET"])
@valid_session_required(api=True) @valid_session_required(api=True)
@rate_limiter.limit("1 per 2 second", key_func = channel_ratelimit_key) @rate_limiter.limit("2 per 2 second", key_func = channel_ratelimit_key)
def fetch(): def fetch():
guild_id = request.args.get("guild_id") guild_id = request.args.get("guild_id")
channel_id = request.args.get('channel_id') channel_id = request.args.get('channel_id')

View File

@ -325,7 +325,7 @@ function run_fetch_routine() {
fill_discord_members(guildobj.discordmembers); fill_discord_members(guildobj.discordmembers);
fill_authenticated_users(guildobj.embedmembers.authenticated); fill_authenticated_users(guildobj.embedmembers.authenticated);
fill_unauthenticated_users(guildobj.embedmembers.unauthenticated); fill_unauthenticated_users(guildobj.embedmembers.unauthenticated);
fetchtimeout = setTimeout(run_fetch_routine, 10000); fetchtimeout = setTimeout(run_fetch_routine, 5000);
}); });
}); });
fet.fail(function(data) { fet.fail(function(data) {