   vars = ('?' for citekey in keys).join(',')
   return ids.concat(Zotero.BetterBibTeX.DB.columnQuery("select itemID from keys where citekey in (#{vars}) and libraryID = ?", keys.concat([library || 0])))
 
-Zotero.BetterBibTeX.schomd.citation = (citekeys, {style, library}) ->
+Zotero.BetterBibTeX.schomd.citation = (citekeys, {style, library} = {}) ->
   items = @items(citekeys, {library: library})
   return '' if items.length == 0
 

    } for item in Zotero.Items.get(results))

Zotero.BetterBibTeX.schomd.bibtex = (keys, {translator, format, library, displayOptions} = {}) ->
  items = Zotero.Items.get(@items(keys, {library: library}))
  translator ?= 'betterbiblatex'
  format ?= 'json'
  displayOptions ?= {}

  cp.updateItems(items)
  return (cp.appendCitationCluster({citationItems: [{id:item}], properties:{}}, true)[0][1] for item in items)

Zotero.BetterBibTeX.schomd.bibliography = (citekeys, {style, library} = {}) ->
  items = @items(citekeys, {library: library})
  return '' if items.length == 0

