check if search exist and is correct in recovery key
This commit is contained in:
parent
04efb9f00c
commit
7b0058e7a5
@ -58,12 +58,28 @@ Pagans.keyrecovery = (emailalias, tribe, search, lg) => {
|
||||
search,
|
||||
lg
|
||||
);
|
||||
if (!search || search.length<3) {
|
||||
console.log(
|
||||
currentmod,
|
||||
"issue with search : emailalias, tribe, search, lg:",
|
||||
emailalias,
|
||||
tribe,
|
||||
search,
|
||||
lg
|
||||
);
|
||||
return {
|
||||
status: 406,
|
||||
ref: "Pagans",
|
||||
msg: "nosearchstring",
|
||||
data: {emailalias,tribe,search,lg},
|
||||
};
|
||||
}
|
||||
if (!["email", "alias"].includes(emailalias)) {
|
||||
return {
|
||||
status: 406,
|
||||
ref: "Pagans",
|
||||
msg: "emailaliasnotemailoralias",
|
||||
data: {},
|
||||
data: {emailalias,tribe,search,lg},
|
||||
};
|
||||
}
|
||||
let emaillist = [];
|
||||
|
Loading…
x
Reference in New Issue
Block a user