Use sender.Context instead of HttpContext.Current, to avoid NullReferenceException.