Skip to content

Commit 2c49020

Browse files
authored
Merge pull request #12 from superfaceai/chore/update_changelog
Update changelog
2 parents cfc30b2 + dc400e2 commit 2c49020

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

88
## Unreleased
9+
### Added
10+
- `users.read` scope added as a minimum default for the strategy to work
911

1012
## 1.0.0 - 2022-01-28
1113

lib/strategy.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,11 +43,11 @@ var OAuth2Strategy = require('passport-oauth2'),
4343
function Strategy(options, verify) {
4444
options = options || {};
4545
options.authorizationURL =
46-
options.authorizationURL || 'https://twitter.com/i/oauth2/authorize';
46+
options.authorizationURL || 'https://twitter.com/i/oauth2/authorize';
4747
options.sessionKey = options.sessionKey || 'oauth:twitter';
4848
options.tokenURL =
49-
options.tokenURL || 'https://api.twitter.com/2/oauth2/token';
50-
options.scope = Array.from(new Set(['users.read', ...options.scope || []]));
49+
options.tokenURL || 'https://api.twitter.com/2/oauth2/token';
50+
options.scope = Array.from(new Set(['users.read', ...(options.scope || [])]));
5151

5252
// Twitter requires clients to use PKCE (RFC 7636)
5353
options.pkce = true;

0 commit comments

Comments
 (0)