Skip to content

Commit

Permalink
handle missing titles and descriptions in graphql
Browse files Browse the repository at this point in the history
  • Loading branch information
Martin Fenner committed Aug 23, 2020
1 parent 879fddf commit f2c6519
Show file tree
Hide file tree
Showing 2 changed files with 55 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/graphql/types/doi_item.rb
Original file line number Diff line number Diff line change
Expand Up @@ -276,11 +276,11 @@ def creators(**args)
end

def titles(first: nil)
object.titles[0...first]
Array.wrap(object.titles)[0...first]
end

def descriptions(first: nil)
object.descriptions[0...first]
Array.wrap(object.descriptions)[0...first]
end

def bibtex
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit f2c6519

Please sign in to comment.