diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-02-11 12:08:52 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-02-11 12:08:52 +0000 |
commit | 05b5c609cb8c260b10c2eb1b92b711dc82d32c3f (patch) | |
tree | 05253c66806b17c5b1f9f13addab59524d536fc4 /app/graphql/types | |
parent | 1078b7bf25c2cb6e03c57da9ae25b0512858556f (diff) | |
download | gitlab-ce-05b5c609cb8c260b10c2eb1b92b711dc82d32c3f.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/graphql/types')
-rw-r--r-- | app/graphql/types/commit_type.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/app/graphql/types/commit_type.rb b/app/graphql/types/commit_type.rb index 392e3ae41c5..eb25e3651a8 100644 --- a/app/graphql/types/commit_type.rb +++ b/app/graphql/types/commit_type.rb @@ -26,6 +26,11 @@ module Types description: 'Rendered HTML of the commit signature' field :author_name, type: GraphQL::STRING_TYPE, null: true, description: 'Commit authors name' + field :author_gravatar, type: GraphQL::STRING_TYPE, null: true, + description: 'Commit authors gravatar', + resolve: -> (commit, args, context) do + GravatarService.new.execute(commit.author_email, 40) + end # models/commit lazy loads the author by email field :author, type: Types::UserType, null: true, |