Allow isReserved() to handle non-string inputs
@@ -6,7 +6,7 @@
*/
exports.isReserved = function (str) {
- var c = str.charCodeAt(0)
+ var c = (str + '').charCodeAt(0)
return c === 0x24 || c === 0x5F
}