pg_conn 0.4.2 → 0.4.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/pg_conn/version.rb +1 -1
- data/lib/pg_conn.rb +2 -2
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 308fc149f0ee84be457ed10f26c2fcb7a8b5ddd21678301820173b067f6a5725
|
4
|
+
data.tar.gz: ea285e08ddc1a5728f7ae022ccd85df8e6312f15f8b8cf7cbdfbf61e1b584a9c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8140b39f3c6930592312b6ac97f9c2a64eead993c37cf6b85caaaa83bcacc723a2a8b14381fcb422d34013290e905d1740b8a9974823fb25e6e3f7debb0c6d27
|
7
|
+
data.tar.gz: 52209c53fd85e21fa6baf2e966d39f75459974c0fd0d8a2086923944f7ad750e0c599d71764add2eb7c88b4ea471a5ee4ce194def68b1586a9e5e49b1a0b0f01
|
data/lib/pg_conn/version.rb
CHANGED
data/lib/pg_conn.rb
CHANGED
@@ -439,14 +439,14 @@ module PgConn
|
|
439
439
|
# (like #tuple), and an array of of tuples if the result contained more
|
440
440
|
# than one record with multiple columns (like #tuples)
|
441
441
|
#
|
442
|
-
def call(name, *args, proc: false)
|
442
|
+
def call(name, *args, proc: false) # :proc may interfere with hashes
|
443
443
|
args_sql = args.map { |arg| # TODO: Use pg's encoder
|
444
444
|
case arg
|
445
445
|
when NilClass; "null"
|
446
446
|
when String; "'#{arg}'"
|
447
447
|
when Integer; arg
|
448
448
|
when TrueClass, FalseClass; arg
|
449
|
-
when Array;
|
449
|
+
when Array; "Array['#{arg.join("', '")}']" # Quick and dirty # FIXME
|
450
450
|
when Hash; raise NotImplementedError
|
451
451
|
else
|
452
452
|
raise ArgumentError, "Unrecognized value: #{arg.inspect}"
|