@andrey4emk/npm-app-back-b24 0.5.30 → 0.5.31
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/sendMessage/wappi.js +2 -2
package/package.json
CHANGED
package/sendMessage/wappi.js
CHANGED
|
@@ -128,14 +128,14 @@ export class Wappi {
|
|
|
128
128
|
});
|
|
129
129
|
let data = await res.json();
|
|
130
130
|
if (data.status != "done") {
|
|
131
|
+
return { error: true, message: `Ошибка проверки номера ${phone} ${messangerType}`, data: data };
|
|
132
|
+
} else {
|
|
131
133
|
// Проверяем нашли max или нет
|
|
132
134
|
let check = false;
|
|
133
135
|
if (data.detail === "found" || data.on_max) {
|
|
134
136
|
check = true;
|
|
135
137
|
}
|
|
136
138
|
return { error: true, message: `Номер ${phone} проверен для мессенджера ${messangerType}`, data: data, check: check };
|
|
137
|
-
} else {
|
|
138
|
-
return { error: false, message: `Сообщение успешно отправлено в ChatApp через ${messangerType}`, data: data };
|
|
139
139
|
}
|
|
140
140
|
}
|
|
141
141
|
}
|