Feat: move notif center fns to own file on the notifier module
Fix: fix jest test
This commit is contained in:
parent
34f2b84fe2
commit
69d3e4cb9b
6 changed files with 204 additions and 190 deletions
|
|
@ -1,5 +1,5 @@
|
|||
const db = require('./db')
|
||||
const notifier = require('./notifier')
|
||||
const notifierQueries = require('./notifier/queries')
|
||||
|
||||
// Get all blacklist rows from the DB "blacklist" table that were manually inserted by the operator
|
||||
const getBlacklist = () => {
|
||||
|
|
@ -15,7 +15,7 @@ const getBlacklist = () => {
|
|||
// Delete row from blacklist table by crypto code and address
|
||||
const deleteFromBlacklist = (cryptoCode, address) => {
|
||||
const sql = `DELETE FROM blacklist WHERE crypto_code = $1 AND address = $2`
|
||||
notifier.clearBlacklistNotification(cryptoCode, address)
|
||||
notifierQueries.clearBlacklistNotification(cryptoCode, address).catch(console.error)
|
||||
return db.none(sql, [cryptoCode, address])
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue