Added code for rate limiting upon search