gitlab-org--gitlab-foss/app/services/milestones/create_service.rb

14 lines
264 B
Ruby
Raw Normal View History

module Milestones
class CreateService < Milestones::BaseService
def execute
milestone = project.milestones.new(params)
2016-04-05 10:51:19 -04:00
if milestone.save!
event_service.open_milestone(milestone, current_user)
end
milestone
end
end
end