debian-mirror-gitlab/lib/api/entities/tree_object.rb
2020-03-13 15:44:24 +05:30

15 lines
303 B
Ruby

# frozen_string_literal: true
module API
module Entities
class TreeObject < Grape::Entity
expose :id, :name, :type, :path
expose :mode do |obj, options|
filemode = obj.mode
filemode = "0" + filemode if filemode.length < 6
filemode
end
end
end
end