comments
This commit is contained in:
1 parent
57fefdc9e2
commit
b86a4216cf
1 file changed
+4
@@ -12,6 +12,10 @@ export default function createNotify(log: Log, pg: Pg, events) {
|
|||||||
|
|
||||||
const subscriber = createSubscriber({ connectionString: process.env.DATABASE_URL });
|
const subscriber = createSubscriber({ connectionString: process.env.DATABASE_URL });
|
||||||
|
|
||||||
|
// pg has a hard limit of 8000B for the notification payload
|
||||||
|
// so we only receive the ids of the updated record
|
||||||
|
// and go fetch the whole thing to figure out who to notify
|
||||||
|
|
||||||
async function handleOffers(payload) {
|
async function handleOffers(payload) {
|
||||||
const { action, id } = payload;
|
const { action, id } = payload;
|
||||||
log.info({ channel: OFFERS_CHANNEL, action, id });
|
log.info({ channel: OFFERS_CHANNEL, action, id });
|
||||||
|
|||||||
Reference in new issue
Block a user