Catch and ignore javascript errors.