 # can be overriden in the second argument.
 
 csv.toArray = (strData) ->
+  if csv.settings.removeTrailingNewlines
+    strData = removeTrailingNewlines(strData)
   strDelimiter = csv.settings.delimiter
 
   rows = []

csv.settings =
  delimiter: ","
  parseFloat: true

@csv = csv


  constructor: (param, opts={})->
    if _isString param
      @string = param
      rows = csv.toArray param
      @rows = arrayToObjects rows
      [@columns, @rowArray...] = rows
    else if _isArray param
