-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
fix(update dependencies): Update dependencies and adjust code and settings #252
Conversation
src/utils.ts
Outdated
@@ -111,7 +111,7 @@ const extractAccessToken = (authHeader: string): string | undefined => { | |||
const setTokeninfo = (req: Request): (data: Token) => void => { | |||
return (data: Token) => { | |||
|
|||
const tokeninfo = { ...data }; | |||
const tokeninfo = { ...data, ...{access_token: undefined} }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note: TS 4.x.x enforces the property to be deleted needs to be an optional - I guess this is less invasive than making the property optional in the type
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
const tokeninfo = { ...data, access_token: undefined };
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
const tokeninfo = { ...data, ...{access_token: undefined} }; | |
const tokeninfo = { | |
...data, | |
access_token: undefined | |
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same idea, oneline or multiline doesn't matter for me, but destructuring shouldn't be needed.
👍 |
"@types/mocha": "8.2.0", | ||
"@types/node-fetch": "2.5.8", | ||
"@types/sinon-chai": "3.2.5", | ||
"@types/sinonjs__fake-timers": "6.0.2", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What the difference to "@sinonjs/fake-timers": "7.0.2",
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just learned this when having a look at koa...this is the way you name @types
packages which are already scoped (@sinonjs
in this case - yeah, that is not nice...)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are the types - sinon is currently implementing types on their own, but are not completely done yet - see https://github.com/sinonjs/fake-timers#help-us-get-our-typescript-definitions-production-ready
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Therefore also the distinct commit
👍 |
1 similar comment
👍 |
close #251