diff options
author | Jacob Vosmaer (GitLab) <jacob@gitlab.com> | 2017-10-03 16:53:11 +0000 |
---|---|---|
committer | Douwe Maan <douwe@gitlab.com> | 2017-10-03 16:53:11 +0000 |
commit | bfd53aa6d087448548c60ec834b7a41dc87ca1e9 (patch) | |
tree | f6cf6b78541efe52423084370bb4bf6c731a80d1 /lib | |
parent | 69fd4f948686f2d0381d5690ac5dbd6e4e411270 (diff) | |
download | gitlab-ce-bfd53aa6d087448548c60ec834b7a41dc87ca1e9.tar.gz |
Restore User.from_gitaly
Diffstat (limited to 'lib')
-rw-r--r-- | lib/gitlab/git/user.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/gitlab/git/user.rb b/lib/gitlab/git/user.rb index cb1af5f3b7c..da74719ae87 100644 --- a/lib/gitlab/git/user.rb +++ b/lib/gitlab/git/user.rb @@ -7,6 +7,11 @@ module Gitlab new(gitlab_user.username, gitlab_user.name, gitlab_user.email, Gitlab::GlId.gl_id(gitlab_user)) end + # TODO support the username field in Gitaly https://gitlab.com/gitlab-org/gitaly/issues/628 + def self.from_gitaly(gitaly_user) + new('', gitaly_user.name, gitaly_user.email, gitaly_user.gl_id) + end + def initialize(username, name, email, gl_id) @username = username @name = name |