Commit f323e782dac5faaabc76c903495a14eddf7f79c2
1 parent
c07bd35b3d
Exists in
master
Penanganan gagal kirim SMS
Showing 1 changed file with 2 additions and 1 deletions Side-by-side Diff
lib/modem.js
... | ... | @@ -272,7 +272,8 @@ async function registerSignalStrengthBackgroundQuery() { |
272 | 272 | async function sendSMS(destination, msg) { |
273 | 273 | if (typeof destination !== 'string' || typeof msg !== 'string' || !destination.trim() || !msg.trim()) return; |
274 | 274 | |
275 | - const parser = new ParserRegex({ regex: REGEX_WAIT_FOR_OK_OR_ERROR }); | |
275 | + // const parser = new ParserRegex({ regex: REGEX_WAIT_FOR_OK_OR_ERROR }); | |
276 | + const parser = new ParserReadline({ delimiter: '\r\n' }); | |
276 | 277 | parser.on('data', () => { |
277 | 278 | port.unpipe(parser); |
278 | 279 | mutex.releaseLockWaitForSubCommand(); |