adding condition case if analytics script is not async