Commit ff40b7de authored by Riyad Preukschas's avatar Riyad Preukschas

Add CommitDecorator#short_id

parent 8b7e404b
class CommitDecorator < ApplicationDecorator
decorates :commit
def short_id(length = 10)
id.to_s[0..length]
end
# Returns the commits title.
#
# Usually, the commit title is the first line of the commit message.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment