fix rate limit checks