File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change 1
1
import { Request , Response } from "express" ;
2
2
3
- import querystring from "node:querystring " ;
3
+ import { URLSearchParams } from "url " ;
4
4
5
5
export default async ( req : Request , res : Response ) => {
6
- const params = querystring . stringify ( {
6
+ const params = new URLSearchParams ( {
7
7
client_id : process . env . github_client_id ,
8
8
redirect_uri : "https://mgp.hrsn.dev/api/callback" ,
9
9
scope : "read:org read:user user:email"
Original file line number Diff line number Diff line change @@ -3,12 +3,12 @@ import SessionData from "../../types/SessionData";
3
3
4
4
import * as Sentry from "@sentry/node" ;
5
5
import axios from "axios" ;
6
- import querystring from "node:querystring " ;
6
+ import { URLSearchParams } from "url " ;
7
7
8
8
export default async ( req : Request & SessionData , res : Response ) => {
9
9
const code = req . query . code as string ;
10
10
11
- const params = querystring . stringify ( {
11
+ const params = new URLSearchParams ( {
12
12
client_id : process . env . github_client_id ,
13
13
client_secret : process . env . github_client_secret ,
14
14
code : code ,
You can’t perform that action at this time.
0 commit comments