overleaf/services/web/app/coffee/Features/Publishers/PublishersGetter.coffee
Timothée Alby 6232854ff7 Remove User Memberships on Deletion (#1688)
Remove User Memberships on Deletion

GitOrigin-RevId: d6e6a4cc01e31288f660c2fd36a0cee174ee5dd1
2019-04-23 14:34:40 +00:00

9 lines
498 B
CoffeeScript

UserMembershipsHandler = require "../UserMembership/UserMembershipsHandler"
UserMembershipEntityConfigs = require "../UserMembership/UserMembershipEntityConfigs"
logger = require 'logger-sharelatex'
_ = require 'underscore'
module.exports = PublishersGetter =
getManagedPublishers: (user_id, callback = (error, managedPublishers) ->) ->
UserMembershipsHandler.getEntitiesByUser UserMembershipEntityConfigs.publisher, user_id, (error, managedPublishers) ->
callback(error, managedPublishers)