This commit is contained in:
lesion
2019-07-31 01:43:08 +02:00
parent a25efc9e59
commit a09b567e97
3 changed files with 28 additions and 17 deletions

View File

@@ -9,6 +9,7 @@ const mail = require('../mail')
const { user: User, event: Event, tag: Tag, place: Place } = require('../models')
const settingsController = require('./settings')
const notifier = require('../../notifier')
const federation = require('../../federation/helpers')
const userController = {
async login(req, res) {
@@ -121,6 +122,8 @@ const userController = {
// send response to client
res.json(event)
federation.sendEvent(event, user)
// send notification (mastodon/email/confirmation)
notifier.notifyEvent(event.id)