Class: Types::ReleaseType

Inherits:
BaseObject
  • Object
show all
Defined in:
app/graphql/types/release_type.rb

Instance Method Summary collapse

Methods inherited from BaseObject

#current_user, #id

Instance Method Details

#authorObject


43
44
45
# File 'app/graphql/types/release_type.rb', line 43

def author
  Gitlab::Graphql::Loaders::BatchModelLoader.new(User, release.author_id).find
end

#commitObject


51
52
53
54
55
# File 'app/graphql/types/release_type.rb', line 51

def commit
  return if release.sha.nil?

  release.project.commit_by(oid: release.sha)
end