summaryrefslogtreecommitdiffstats
path: root/samples/OpenIdProviderMvc/Controllers/AccountController.cs
diff options
context:
space:
mode:
authorAndrew Arnott <andrewarnott@gmail.com>2012-03-21 22:58:36 -0700
committerAndrew Arnott <andrewarnott@gmail.com>2012-03-21 22:58:36 -0700
commit80028b1c5442c85909b889b3c52cfbd0c0121437 (patch)
treeb1b651c08a349957bb3d26ad5234a266d8d3e42e /samples/OpenIdProviderMvc/Controllers/AccountController.cs
parentf02ccf1e93367b7ab8bece3a2c53e960e98d221d (diff)
parente1455ee979b150d1ea4afdf1bc82a9e5cbc5b2ba (diff)
downloadDotNetOpenAuth-80028b1c5442c85909b889b3c52cfbd0c0121437.zip
DotNetOpenAuth-80028b1c5442c85909b889b3c52cfbd0c0121437.tar.gz
DotNetOpenAuth-80028b1c5442c85909b889b3c52cfbd0c0121437.tar.bz2
Merge branch 'v4.0' into dev11
Conflicts: src/DotNetOpenAuth.sln
Diffstat (limited to 'samples/OpenIdProviderMvc/Controllers/AccountController.cs')
-rw-r--r--samples/OpenIdProviderMvc/Controllers/AccountController.cs20
1 files changed, 10 insertions, 10 deletions
diff --git a/samples/OpenIdProviderMvc/Controllers/AccountController.cs b/samples/OpenIdProviderMvc/Controllers/AccountController.cs
index cbc6561..7cb4b62 100644
--- a/samples/OpenIdProviderMvc/Controllers/AccountController.cs
+++ b/samples/OpenIdProviderMvc/Controllers/AccountController.cs
@@ -55,7 +55,7 @@
}
this.FormsAuth.SignIn(userName, rememberMe);
- if (!String.IsNullOrEmpty(returnUrl)) {
+ if (!string.IsNullOrEmpty(returnUrl)) {
return Redirect(returnUrl);
} else {
return RedirectToAction("Index", "Home");
@@ -173,16 +173,16 @@
}
private bool ValidateChangePassword(string currentPassword, string newPassword, string confirmPassword) {
- if (String.IsNullOrEmpty(currentPassword)) {
+ if (string.IsNullOrEmpty(currentPassword)) {
ModelState.AddModelError("currentPassword", "You must specify a current password.");
}
if (newPassword == null || newPassword.Length < this.MembershipService.MinPasswordLength) {
ModelState.AddModelError(
"newPassword",
- String.Format(CultureInfo.CurrentCulture, "You must specify a new password of {0} or more characters.", this.MembershipService.MinPasswordLength));
+ string.Format(CultureInfo.CurrentCulture, "You must specify a new password of {0} or more characters.", this.MembershipService.MinPasswordLength));
}
- if (!String.Equals(newPassword, confirmPassword, StringComparison.Ordinal)) {
+ if (!string.Equals(newPassword, confirmPassword, StringComparison.Ordinal)) {
ModelState.AddModelError("_FORM", "The new password and confirmation password do not match.");
}
@@ -190,10 +190,10 @@
}
private bool ValidateLogOn(string userName, string password) {
- if (String.IsNullOrEmpty(userName)) {
+ if (string.IsNullOrEmpty(userName)) {
ModelState.AddModelError("username", "You must specify a username.");
}
- if (String.IsNullOrEmpty(password)) {
+ if (string.IsNullOrEmpty(password)) {
ModelState.AddModelError("password", "You must specify a password.");
}
if (!this.MembershipService.ValidateUser(userName, password)) {
@@ -204,18 +204,18 @@
}
private bool ValidateRegistration(string userName, string email, string password, string confirmPassword) {
- if (String.IsNullOrEmpty(userName)) {
+ if (string.IsNullOrEmpty(userName)) {
ModelState.AddModelError("username", "You must specify a username.");
}
- if (String.IsNullOrEmpty(email)) {
+ if (string.IsNullOrEmpty(email)) {
ModelState.AddModelError("email", "You must specify an email address.");
}
if (password == null || password.Length < this.MembershipService.MinPasswordLength) {
ModelState.AddModelError(
"password",
- String.Format(CultureInfo.CurrentCulture, "You must specify a password of {0} or more characters.", this.MembershipService.MinPasswordLength));
+ string.Format(CultureInfo.CurrentCulture, "You must specify a password of {0} or more characters.", this.MembershipService.MinPasswordLength));
}
- if (!String.Equals(password, confirmPassword, StringComparison.Ordinal)) {
+ if (!string.Equals(password, confirmPassword, StringComparison.Ordinal)) {
ModelState.AddModelError("_FORM", "The new password and confirmation password do not match.");
}
return ModelState.IsValid;