@ -306,6 +306,8 @@ authenticationController.logout = function(req, res, next) {
}
req.logout();
user.setUserField(uid, 'lastonline', Date.now() - 300000);
// action:user.loggedOut deprecated in > v0.9.3
plugins.fireHook('action:user.loggedOut', {req: req, res: res, uid: uid});
plugins.fireHook('static:user.loggedOut', {req: req, res: res, uid: uid}, function() {
@ -1,10 +1,10 @@
'use strict';
var async = require('async'),
winston = require('winston'),
db = require('../database'),
meta = require('../meta'),
events = require('../events');
var async = require('async');
var winston = require('winston');
var db = require('../database');
var meta = require('../meta');
var events = require('../events');
module.exports = function(User) {
User.auth = {};