Include message ID in log, fix message

This commit is contained in:
Bryan Ashby 2023-04-20 20:33:19 -06:00
parent 95c249fc23
commit beb28c9696
No known key found for this signature in database
GPG Key ID: C2C1B501E4EFD994
1 changed files with 3 additions and 2 deletions

View File

@ -994,7 +994,7 @@ exports.getModule = class ActivityPubWebHandler extends WebHandlerModule {
return cb(err);
}
message.persist(err => {
message.persist((err, messageId) => {
if (!err) {
if (_.isObject(localAddressedTo)) {
localAddressedTo = localAddressedTo.username;
@ -1004,8 +1004,9 @@ exports.getModule = class ActivityPubWebHandler extends WebHandlerModule {
localAddressedTo,
activityId,
noteId: note.id,
messageId,
},
'Note delivered as message to private mailbox'
'Note persisted as local Message'
);
} else if (err.code === 'SQLITE_CONSTRAINT') {
return cb(null);