Bug 827383 - Fixing setTimeout function issues.