private void SendConfirmationMail(HttpContextBase context, User user, Culture culture = Culture.En) { var confirmationMessageSender = new ConfirmationMailSender(); string token = SecurityManager.GetHashString(user.Email + user.Password); if (context.Request.Url != null) { string path = context.Request.Url.GetLeftPart(UriPartial.Authority) + "/User/Confirm?hash=" + token; string message = String.Format(StaticSettings.ConfirmationMessage(culture) + "{0}", path); confirmationMessageSender.Send(StaticSettings.ConfirmationTitle(culture), message, user.Email); } }