Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Merge pull request #100 from mattmatt/master

Convert multipart buffer to string before regex'ing it
  • Loading branch information...
commit f2096bd02609a8746628736f6bf983ed3a71006a 2 parents 3a0da2e + d7d1c64
Francisco Treacy authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/utils.coffee
View
4 src/utils.coffee
@@ -6,7 +6,7 @@ module.exports =
escape = (text) -> text.replace /[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&"
- data = data.split(new RegExp("\r?\n--#{escape boundary}--\r?\n"))?[0] or ""
+ data = data.toString().split(new RegExp("\r?\n--#{escape boundary}--\r?\n"))?[0] or ""
data.split(new RegExp("\r?\n--#{escape boundary}\r?\n")).filter((e) -> !!e).map (part) ->
@@ -98,4 +98,4 @@ module.exports =
# else
# target[key] = value
#
- # return a
+ # return a
Please sign in to comment.
Something went wrong with that request. Please try again.