This commit is contained in:
syuilo 2017-03-12 07:23:13 +09:00
parent e71b0a57b9
commit a4736a6c71

View file

@ -1,6 +1,7 @@
/**
* Module dependencies
*/
import User from '../models/user';
import serialize from '../serializers/user';
/**
@ -18,4 +19,11 @@ module.exports = (params, user, _, isSecure) => new Promise(async (res, rej) =>
detail: true,
includeSecrets: isSecure
}));
// Update lastUsedAt
User.update({ _id: user._id }, {
$set: {
last_used_at: new Date()
}
});
});