[#7] Refactor the RateLimiter code (get rid of long if/else statement in call method)