Merge remote-tracking branch 'origin/release-8.1' into release-8.6

This commit is contained in:
Rafael Taranto 2023-08-22 13:13:41 +01:00
commit 0079edb9dc
20 changed files with 970 additions and 95 deletions

View file

@ -1,5 +1,4 @@
const _ = require('lodash/fp')
const argv = require('minimist')(process.argv.slice(2))
const crypto = require('crypto')
const pgp = require('pg-promise')()
const dateFormat = require('dateformat')
@ -201,11 +200,9 @@ function plugins (settings, deviceId) {
const virtualCassettes = [Math.max(...denominations) * 2]
const counts = argv.cassettes
? argv.cassettes.split(',')
: _cassettes.counts
const counts = _cassettes.counts
if (_cassettes.counts.length !== denominations.length) {
if (counts.length !== denominations.length) {
throw new Error('Denominations and respective counts do not match!')
}
@ -961,7 +958,9 @@ function plugins (settings, deviceId) {
}
function getPhoneCode (phone) {
const code = argv.mockSms
const notifications = configManager.getNotifications(settings.config)
const code = notifications.thirdParty_sms === 'mock-sms'
? '123'
: randomCode()