mirror of https://github.com/zulip/zulip.git
signup: Rename validation method
Otherwise it applies to all password-type <input>s, which is not necessarily what we want. (imported from commit da2bb86961f4ff1dcc48e89e51abac6dbea79548)
This commit is contained in:
parent
01a20d9c56
commit
0962f7399d
|
@ -2,7 +2,7 @@ $(function () {
|
|||
// NB: this file is included on multiple pages. In each context,
|
||||
// some of the jQuery selectors below will return empty lists.
|
||||
|
||||
$.validator.addMethod('password', function (value, element) {
|
||||
$.validator.addMethod('password_strength', function (value, element) {
|
||||
return password_quality(value);
|
||||
}, 'Password is weak.');
|
||||
|
||||
|
@ -17,7 +17,7 @@ $(function () {
|
|||
|
||||
$('#registration').validate({
|
||||
rules: {
|
||||
id_password: 'password'
|
||||
password: 'password_strength',
|
||||
},
|
||||
errorElement: "p",
|
||||
errorPlacement: function (error, element) {
|
||||
|
|
Loading…
Reference in New Issue