github-graphql 1.2.1 → 1.2.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/github/graphql.rb +2 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e2a1e80140f87cf9aed84e103b233e418c44d37f
|
4
|
+
data.tar.gz: d36a972a94a9fce48122b4a0a0e288a120b42751
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 651daf68796686e601fa6212e75dac45ee187a92d4ab7c909b257a0d6bf34f041d1358ed447c216415c86e05b64e81da1236947443de57e037bb55d61e534ac2
|
7
|
+
data.tar.gz: d8b23cd44f0cc95228c5912e1adc9e41dc30274513a3c919a7588e4c0b62ee8b5bca1146e681fe8a4d84bed4da624e0f3271095a1eb39ea8f73eb63b45b7a691
|
data/lib/github/graphql.rb
CHANGED
@@ -37,7 +37,8 @@ module Github
|
|
37
37
|
# Will raise an ArgumentError if token is nil
|
38
38
|
#
|
39
39
|
def token(token)
|
40
|
-
raise ArgumentError, '
|
40
|
+
raise ArgumentError, 'Invalid Token', caller unless
|
41
|
+
token =~ /\A[A-Za-z0-9]{40,40}\z/
|
41
42
|
@request['Authorization'] = "bearer #{token}"
|
42
43
|
end
|
43
44
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: github-graphql
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.2.
|
4
|
+
version: 1.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Caleb Smith
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-08-
|
11
|
+
date: 2017-08-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: json
|