warden-github 0.6.0 → 0.6.1
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/warden-github/user.rb +3 -3
- data/lib/warden-github/version.rb +1 -1
- metadata +3 -3
data/lib/warden-github/user.rb
CHANGED
@@ -77,7 +77,7 @@ module Warden
|
|
77
77
|
# params - extra params for calling the api
|
78
78
|
#
|
79
79
|
def post(path, params)
|
80
|
-
headers = {:Authorization => "token #{
|
80
|
+
headers = {:Authorization => "token #{token}", :content_type => :json, :accept => :json}
|
81
81
|
res = RestClient.post("#{github_api_uri}/#{path}", params.to_json, headers)
|
82
82
|
Yajl.load(res)
|
83
83
|
end
|
@@ -88,7 +88,7 @@ module Warden
|
|
88
88
|
# params - extra params for calling the api
|
89
89
|
#
|
90
90
|
def put(path, params)
|
91
|
-
headers = {:Authorization => "token #{
|
91
|
+
headers = {:Authorization => "token #{token}", :content_type => :json, :accept => :json}
|
92
92
|
res = RestClient.put("#{github_api_uri}/#{path}", params.to_json, headers)
|
93
93
|
Yajl.load(res)
|
94
94
|
end
|
@@ -99,7 +99,7 @@ module Warden
|
|
99
99
|
# params - extra params for calling the api
|
100
100
|
#
|
101
101
|
def delete(path, params)
|
102
|
-
headers = {:Authorization => "token #{
|
102
|
+
headers = {:Authorization => "token #{token}", :content_type => :json, :accept => :json}
|
103
103
|
res = RestClient.delete("#{github_api_uri}/#{path}", params.to_json, headers)
|
104
104
|
Yajl.load(res)
|
105
105
|
end
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: warden-github
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 5
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 6
|
9
|
-
-
|
10
|
-
version: 0.6.
|
9
|
+
- 1
|
10
|
+
version: 0.6.1
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Corey Donohoe
|