Add try/catch block.

When ran on a background thread HttpContext.Current will be null and will raise a NullReference exception.

See related raygun log: https://app.raygun.io/dashboard/7cyo1v/errors/511897671?