debian-mirror-gitlab/app/models/generic_commit_status.rb
2016-06-02 11:05:42 +05:30

15 lines
273 B
Ruby

class GenericCommitStatus < CommitStatus
before_validation :set_default_values
# GitHub compatible API
alias_attribute :context, :name
def set_default_values
self.context ||= 'default'
self.stage ||= 'external'
end
def tags
[:external]
end
end