Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Throw Errors

  • Loading branch information...
commit f1b35e92fe1614714581331a52d45d5f34e90dda 1 parent 3bc78b7
@tj tj authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  lib/cookies.js
View
2  lib/cookies.js
@@ -46,7 +46,7 @@ Cookies.prototype = {
if (typeof headers == "string") headers = [headers]
- if (!secure && opts && opts.secure) throw "Cannot send secure cookie over unencrypted socket"
+ if (!secure && opts && opts.secure) throw new Error("Cannot send secure cookie over unencrypted socket")
cookie.secure = secure
if (opts && "secure" in opts) cookie.secure = opts.secure
Please sign in to comment.
Something went wrong with that request. Please try again.