overleaf/services/web/app/coffee/Features/Publishers/PublishersGetter.coffee
Douglas Lovell 740dce07a9 Merge remote-tracking branch 'origin/hb-publisher-management'
GitOrigin-RevId: 746cb15097cdc7c4f4cbd9f029d5e456c9bfe3ad
2018-12-18 13:42:56 +00:00

9 lines
495 B
CoffeeScript

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