Project

General

Profile

Defect #30491 ยป short_description_fix.diff

Go MAEDA, 2019-01-25 01:55

View differences:

app/models/project.rb (working copy)
name
end
# Returns a short description of the projects (first lines)
# Returns a short description of the projects (first 3 lines)
def short_description(length = 255)
description.gsub(/^(.{#{length}}[^\n\r]*).*$/m, '\1...').strip if description
if description
description =~ /\A(?>[^\r\n]*(?:\r\n?|\n)?){0,3}/
s = $&.strip[0...length]
s << '...' if s != description
end
end
def css_classes
    (1-1/1)