Skip to content

Commit

Permalink
feat: rename Client.getAuthUrl() -> Client.makeAuthUrl()
Browse files Browse the repository at this point in the history
BREAKING CHANGE: `Client.getAuthUrl()` has been renamed to
`Client.makeAuthUrl()`.
  • Loading branch information
thislooksfun committed Feb 3, 2022
1 parent 6ffe0cc commit ba87fdf
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion examples/oauth/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ app.get("/", (_req, res) => res.send("Hello world!"));

// When the user navigates to /login redirect them to the Reddit OAuth url.
app.get("/login", (_req, res) => {
const uri = Client.getAuthUrl(
const uri = Client.makeAuthUrl(
creds.clientId,
["identity"],
redirectUri,
Expand Down
4 changes: 2 additions & 2 deletions src/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ export default class Client {
}

/**
* Get an OAuth login url.
* Make an OAuth login url.
*
* @param clientId The ID of the Reddit app.
* @param scopes The scopes to authorize with.
Expand All @@ -190,7 +190,7 @@ export default class Client {
*
* @returns The URL to direct the user to for authorization.
*/
static getAuthUrl(
static makeAuthUrl(
clientId: string,
scopes: string[],
redirectUri: string,
Expand Down

0 comments on commit ba87fdf

Please sign in to comment.