settimeout for better performance