Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 4d22626

Browse filesBrowse files
authored
common.rb - update REST headers (#10)
1 parent 779cfad commit 4d22626
Copy full SHA for 4d22626

File tree

Expand file treeCollapse file tree

1 file changed

+2
-1
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+2
-1
lines changed

‎common.rb

Copy file name to clipboardExpand all lines: common.rb
+2-1Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,9 @@ def gh_upload_http
7474

7575
def set_v3_common_headers(req, connection: nil)
7676
req['User-Agent'] = GH_NAME
77-
req['Authorization'] = "token #{TOKEN}"
77+
req['Authorization'] = "Bearer #{TOKEN}"
7878
req['Accept'] = 'application/vnd.github+json' # old 'application/vnd.github.v3+json'
79+
req['X-GitHub-Api-Version'] = '2022-11-28'
7980
req['Connection'] = 'close' if connection == 'close'
8081
end
8182

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.