debian-mirror-gitlab/lib/gitlab/gl_id.rb

16 lines
228 B
Ruby
Raw Normal View History

module Gitlab
module GlId
def self.gl_id(user)
if user.present?
2018-10-15 14:42:47 +05:30
gl_id_from_id_value(user.id)
else
2018-10-15 14:42:47 +05:30
''
end
end
2018-10-15 14:42:47 +05:30
def self.gl_id_from_id_value(id)
"user-#{id}"
end
end
end