     buffer.getTextInRange([start, end])
 
   prettifyTitle: (title) ->
+    return if not title
+
     if (colon = title.indexOf(':')) isnt -1 and title.words().length > 5
       title = title.substring(0, colon)
 
     title.titleize().truncateOnWord 30, 'middle'
 
   cleanAuthors: (authors) ->
-    if not authors? then return [{ familyName: 'Unknown' }]
+    return [{ familyName: 'Unknown' }] if not authors?
 
     for author in authors
       [familyName, personalName] =

      bibtex = []

      for file in bibtexFiles
        parser = new bibtexParse(fs.readFileSync(file, 'utf-8'))

        bibtex = bibtex.concat parser.parse()

      @bibtex = bibtex
    catch error

  ###
  wordRegex: /(?:^|\s)@[^\s@]*/
  constructor: ->
    @bibtex = []

    @buildWordList(atom.config.get "autocomplete-bibtex.bibtex")
    atom.config.observe "autocomplete-bibtex.bibtex", (bibtexFiles) =>
      @buildWordList(bibtexFiles)
