gitlab-org--gitlab-foss/app/services/wiki_pages/base_service.rb

14 lines
363 B
Ruby
Raw Normal View History

# frozen_string_literal: true
module WikiPages
class BaseService < ::BaseService
private
def execute_hooks(page, action = 'create')
2017-07-20 11:12:06 -04:00
page_data = Gitlab::DataBuilder::WikiPage.build(page, current_user, action)
@project.execute_hooks(page_data, :wiki_page_hooks)
@project.execute_services(page_data, :wiki_page_hooks)
end
end
end