 
       # prefer to end the teaser at the end of a sentence (a period).
       # failing that prefer to end the teaser at the end of a word (a space).
-      candidate = tryToShorten(longText, '.') or tryToShorten longText, ' ', '...'
+      candidate = tryToShorten(longText, '. ', suffix) or tryToShorten longText, ' ', suffix
 
       if candidate?.length > minLength
-        candidate
+        Encoder.htmlEncode candidate
       else
-        longText
+        Encoder.htmlEncode longText
 
   getMonthOptions : ()->
     ((if i > 9 then { title : "#{i}", value : i} else { title : "0#{i}", value : i}) for i in [1..12])

      return unless longText
      minLength = options.minLength or 450
      maxLength = options.maxLength or 600

      return longText if longText < minLength or longText < maxLength


  stripTags:(value)->
    value.replace /<(?:.|\n)*?>/gm, ''

  applyTextExpansions: (text, shorten)->
    return null unless text
    # @expandWwwDotDomains @expandUrls @expandUsernames @expandTags text
    text = text.replace '&#10;', ' '
    text = __utils.putShowMore text if shorten
    @expandWwwDotDomains @expandUrls @expandUsernames text

  expandWwwDotDomains: (text) ->
