Skip to content

Commit 2ef92dd

Browse files
committed
chore(rebase): Merge with latest crow main branch
2 parents f8a81ef + 83e2f6b commit 2ef92dd

File tree

20 files changed

+171
-30
lines changed

20 files changed

+171
-30
lines changed

.github/workflows/update-dependencies.yml

Lines changed: 0 additions & 22 deletions
This file was deleted.

changelog.md

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
55

66
# [5.0.0-pre.0](https://github.com/feathersjs/feathers/compare/v4.5.4...v5.0.0-pre.0) (2020-05-19)
77

8-
98
### Bug Fixes
109

1110
* **authentication-oauth:** Updated typings for projects with strictNullChecks ([#1941](https://github.com/feathersjs/feathers/issues/1941)) ([be91206](https://github.com/feathersjs/feathers/commit/be91206e3dba1e65a81412b7aa636bece3ab4aa2))
@@ -34,8 +33,24 @@ functionality like path replacements and automatic environment variable insertio
3433

3534

3635

36+
37+
## [4.5.9](https://github.com/feathersjs/feathers/compare/v4.5.8...v4.5.9) (2020-10-09)
38+
39+
40+
### Bug Fixes
41+
42+
* **authentication-local:** Keep non-objects in protect hook ([#2085](https://github.com/feathersjs/feathers/issues/2085)) ([5a65e2e](https://github.com/feathersjs/feathers/commit/5a65e2e6cee0a15614f23ee2e0d3c25d3365027d))
43+
* **authentication-oauth:** Always end session after oAuth flows are finished ([#2087](https://github.com/feathersjs/feathers/issues/2087)) ([d219d0d](https://github.com/feathersjs/feathers/commit/d219d0d89c5e45aa289dd67cb0c8bdc05044c846))
44+
* **configuration:** Fix handling of config values that start with . or .. but are not actually relative paths; e.g. ".foo" or "..bar" ([#2065](https://github.com/feathersjs/feathers/issues/2065)) ([d07bf59](https://github.com/feathersjs/feathers/commit/d07bf5902e9c8c606f16b9523472972d3d2e9b49))
45+
* **rest-client:** Handle non-JSON errors with fetch adapter ([#2086](https://github.com/feathersjs/feathers/issues/2086)) ([e24217a](https://github.com/feathersjs/feathers/commit/e24217ad1e784ad71cd9d64fe1727dd02f039991))
46+
47+
48+
49+
50+
3751
## [4.5.8](https://github.com/feathersjs/feathers/compare/v4.5.7...v4.5.8) (2020-08-12)
3852

53+
3954
* **authentication-client:** Fix storage type so it works with all supported interfaces ([#2041](https://github.com/feathersjs/feathers/issues/2041)) ([6ee0e78](https://github.com/feathersjs/feathers/commit/6ee0e78d55cf1214f61458f386b94c350eec32af))
4055

4156

packages/authentication-client/CHANGELOG.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,15 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
1717

1818

1919

20+
21+
## [4.5.9](https://github.com/feathersjs/feathers/compare/v4.5.8...v4.5.9) (2020-10-09)
22+
23+
**Note:** Version bump only for package @feathersjs/authentication-client
24+
25+
26+
27+
28+
2029
## [4.5.8](https://github.com/feathersjs/feathers/compare/v4.5.7...v4.5.8) (2020-08-12)
2130

2231

packages/authentication-local/src/hooks/protect.ts

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,14 @@ import { HookContext } from '@feathersjs/feathers';
44
export default (...fields: string[]) => (context: HookContext) => {
55
const result = context.dispatch || context.result;
66
const o = (current: any) => {
7-
const data = typeof current.toJSON === 'function'
8-
? current.toJSON() : current;
9-
return omit(data, fields);
7+
if (typeof current === 'object' && !Array.isArray(current)) {
8+
const data = typeof current.toJSON === 'function'
9+
? current.toJSON() : current;
10+
11+
return omit(data, fields);
12+
}
13+
14+
return current;
1015
};
1116

1217
if (!result) {

packages/authentication-local/test/hooks/protect.test.ts

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -82,14 +82,16 @@ function testOmit (title: string, property: string) {
8282
});
8383
});
8484

85-
it('omits from array', () => {
85+
it('omits from array but only objects (#2053)', () => {
8686
const data = [{
8787
email: 'test1@user.com',
8888
password: 'supersecret'
8989
}, {
9090
email: 'test2@user.com',
9191
password: 'othersecret'
92-
}];
92+
}, [
93+
'one', 'two', 'three'
94+
], 'test'];
9395
const context = {
9496
[property]: data
9597
} as unknown as HookContext;
@@ -99,7 +101,9 @@ function testOmit (title: string, property: string) {
99101
[property]: data,
100102
dispatch: [
101103
{ email: 'test1@user.com' },
102-
{ email: 'test2@user.com' }
104+
{ email: 'test2@user.com' }, [
105+
'one', 'two', 'three'
106+
], 'test'
103107
]
104108
});
105109
});

packages/authentication-oauth/CHANGELOG.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,18 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
99

1010

1111

12+
13+
## [4.5.9](https://github.com/feathersjs/feathers/compare/v4.5.8...v4.5.9) (2020-10-09)
14+
15+
16+
### Bug Fixes
17+
18+
* **authentication-oauth:** Always end session after oAuth flows are finished ([#2087](https://github.com/feathersjs/feathers/issues/2087)) ([d219d0d](https://github.com/feathersjs/feathers/commit/d219d0d89c5e45aa289dd67cb0c8bdc05044c846))
19+
20+
21+
22+
23+
1224
## [4.5.8](https://github.com/feathersjs/feathers/compare/v4.5.7...v4.5.8) (2020-08-12)
1325

1426
**Note:** Version bump only for package @feathersjs/authentication-oauth

packages/authentication-oauth/src/express.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,10 @@ export default (options: OauthSetupSettings) => {
8989
...payload
9090
};
9191

92+
await new Promise((resolve, reject) =>
93+
req.session.destroy(err => err ? reject(err) : resolve())
94+
);
95+
9296
debug(`Calling ${authService}.create authentication with strategy ${name}`);
9397

9498
const authResult = await service.create(authentication, params);

packages/authentication/CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,17 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
55

66
# [5.0.0-pre.0](https://github.com/feathersjs/feathers/compare/v4.5.4...v5.0.0-pre.0) (2020-05-19)
77

8+
9+
10+
11+
## [4.5.9](https://github.com/feathersjs/feathers/compare/v4.5.8...v4.5.9) (2020-10-09)
12+
813
**Note:** Version bump only for package @feathersjs/authentication
914

1015

1116

17+
18+
1219
## [4.5.8](https://github.com/feathersjs/feathers/compare/v4.5.7...v4.5.8) (2020-08-12)
1320

1421
**Note:** Version bump only for package @feathersjs/authentication

packages/client/CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,14 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
2222

2323

2424

25+
## [4.5.9](https://github.com/feathersjs/feathers/compare/v4.5.8...v4.5.9) (2020-10-09)
26+
27+
**Note:** Version bump only for package @feathersjs/client
28+
29+
30+
31+
32+
2533
## [4.5.8](https://github.com/feathersjs/feathers/compare/v4.5.7...v4.5.8) (2020-08-12)
2634

2735
**Note:** Version bump only for package @feathersjs/client

packages/commons/CHANGELOG.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,15 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
1313

1414

1515

16+
17+
## [4.5.9](https://github.com/feathersjs/feathers/compare/v4.5.8...v4.5.9) (2020-10-09)
18+
19+
**Note:** Version bump only for package @feathersjs/commons
20+
21+
22+
23+
24+
1625
## [4.5.8](https://github.com/feathersjs/feathers/compare/v4.5.7...v4.5.8) (2020-08-12)
1726

1827
**Note:** Version bump only for package @feathersjs/commons

0 commit comments

Comments
 (0)