Comparing version 0.0.1 to 0.0.2
@@ -27,4 +27,5 @@ | ||
return fmt.replace(/%([%sIL])/g, function(_, type){ | ||
if ('%' == type) return '%'; | ||
var arg = args[i++]; | ||
switch (type) { | ||
@@ -34,3 +35,2 @@ case 's': return exports.string(arg); | ||
case 'L': return exports.literal(arg); | ||
case '%': return '%'; | ||
} | ||
@@ -37,0 +37,0 @@ }); |
{ | ||
"name": "pg-escape", | ||
"version": "0.0.1", | ||
"version": "0.0.2", | ||
"repository": "segmentio/pg-escape", | ||
@@ -5,0 +5,0 @@ "description": "escape postgres queries which do not support stored procedures", |
# name | ||
# pg-escape | ||
description | ||
Sprintf-style postgres query formatting and escape helper functions. | ||
@@ -9,3 +9,3 @@ ## Installation | ||
``` | ||
$ npm install name | ||
$ npm install pg-escape | ||
``` | ||
@@ -12,0 +12,0 @@ |
@@ -21,2 +21,7 @@ | ||
}) | ||
it('should not eat args', function(){ | ||
escape('just %% a %s', 'test') | ||
.should.equal('just % a test'); | ||
}) | ||
}) | ||
@@ -84,2 +89,3 @@ | ||
}) | ||
}) | ||
}) | ||
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
5610
7
159