Merge pull request #241 from status-im/feature/password-validation
Password validation in !keypair command
Former-commit-id: 20d08c8466
This commit is contained in:
commit
8201cf286c
|
@ -1,4 +1,3 @@
|
||||||
|
|
||||||
var phones = [
|
var phones = [
|
||||||
{
|
{
|
||||||
number: "89171111111",
|
number: "89171111111",
|
||||||
|
@ -186,6 +185,18 @@ status.response({
|
||||||
params: [params.value]
|
params: [params.value]
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
validator: function (params) {
|
||||||
|
if(!params.value || params.value.length < 6){
|
||||||
|
return {
|
||||||
|
errors: [
|
||||||
|
status.components.validationMessage(
|
||||||
|
"Password",
|
||||||
|
"Password should be not less then 6 symbols."
|
||||||
|
)
|
||||||
|
]
|
||||||
|
};
|
||||||
|
}
|
||||||
|
},
|
||||||
preview: function (params) {
|
preview: function (params) {
|
||||||
return status.components.text(
|
return status.components.text(
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue