@feathersjs/authentication 5.0.6 → 5.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,22 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [5.0.8](https://github.com/feathersjs/feathers/compare/v5.0.7...v5.0.8) (2023-07-19)
7
+
8
+ **Note:** Version bump only for package @feathersjs/authentication
9
+
10
+
11
+
12
+
13
+
14
+ ## [5.0.7](https://github.com/feathersjs/feathers/compare/v5.0.6...v5.0.7) (2023-07-14)
15
+
16
+ **Note:** Version bump only for package @feathersjs/authentication
17
+
18
+
19
+
20
+
21
+
6
22
  ## [5.0.6](https://github.com/feathersjs/feathers/compare/v5.0.5...v5.0.6) (2023-06-15)
7
23
 
8
24
  ### Bug Fixes
package/lib/service.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import '@feathersjs/transport-commons';
2
- import { ServiceMethods, ServiceAddons } from '@feathersjs/feathers';
2
+ import { ServiceMethods } from '@feathersjs/feathers';
3
3
  import { AuthenticationBase, AuthenticationResult, AuthenticationRequest, AuthenticationParams } from './core';
4
4
  declare module '@feathersjs/feathers/lib/declarations' {
5
5
  interface FeathersApplication<Services, Settings> {
@@ -16,8 +16,6 @@ declare module '@feathersjs/feathers/lib/declarations' {
16
16
  authentication?: AuthenticationRequest;
17
17
  }
18
18
  }
19
- export interface AuthenticationService extends ServiceAddons<AuthenticationResult, AuthenticationResult> {
20
- }
21
19
  export declare class AuthenticationService extends AuthenticationBase implements Partial<ServiceMethods<AuthenticationResult, AuthenticationRequest, AuthenticationParams>> {
22
20
  constructor(app: any, configKey?: string, options?: {});
23
21
  /**
package/lib/service.js CHANGED
@@ -138,8 +138,9 @@ class AuthenticationService extends core_1.AuthenticationBase {
138
138
  throw new Error(`The '${service}' service does not have an 'id' property and no 'entityId' option is set.`);
139
139
  }
140
140
  }
141
- if (typeof this.publish === 'function') {
142
- this.publish(() => null);
141
+ const publishable = this;
142
+ if (typeof publishable.publish === 'function') {
143
+ publishable.publish(() => null);
143
144
  }
144
145
  }
145
146
  }
@@ -1 +1 @@
1
- {"version":3,"file":"service.js","sourceRoot":"","sources":["../src/service.ts"],"names":[],"mappings":";;;;;;AAAA,yDAAgC;AAChC,+CAAqD;AACrD,yCAAsC;AACtC,iDAAiD;AAEjD,+CAAoD;AACpD,gEAAuC;AACvC,6CAAyC;AAEzC,iCAA8G;AAC9G,mCAA2C;AAE3C,MAAM,KAAK,GAAG,IAAA,qBAAW,EAAC,oCAAoC,CAAC,CAAA;AAwB/D,MAAa,qBACX,SAAQ,yBAAkB;IAG1B,YAAY,GAAQ,EAAE,SAAS,GAAG,gBAAgB,EAAE,OAAO,GAAG,EAAE;QAC9D,KAAK,CAAC,GAAG,EAAE,SAAS,EAAE,OAAO,CAAC,CAAA;QAE9B,IAAA,aAAK,EAAC,IAAI,EAAE;YACV,MAAM,EAAE,CAAC,IAAA,wBAAe,GAAE,EAAE,IAAA,aAAK,EAAC,OAAO,CAAC,EAAE,IAAA,kBAAU,EAAC,OAAO,CAAC,CAAC;YAChE,MAAM,EAAE,CAAC,IAAA,wBAAe,GAAE,EAAE,IAAA,aAAK,EAAC,QAAQ,CAAC,EAAE,IAAA,kBAAU,EAAC,QAAQ,CAAC,CAAC;SACnE,CAAC,CAAA;QAEF,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,YAAY,EAAE,KAAK,EAAE,UAAU,EAAE,EAAE;YAC7C,MAAM,IAAI,CAAC,gBAAgB,CAAC,YAAY,EAAE,UAAU,CAAC,CAAA;QACvD,CAAC,CAAC,CAAA;QAEF,IAAI,OAAO,GAAG,CAAC,qBAAqB,KAAK,UAAU,EAAE;YACnD,GAAG,CAAC,qBAAqB,GAAG,UAAU,QAAiB;gBACrD,MAAM,SAAS,GAAG,GAAG,CAAC,GAAG,CAAC,uBAAuB,CAA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  {
2
2
  "name": "@feathersjs/authentication",
3
3
  "description": "Add Authentication to your FeathersJS app.",
4
- "version": "5.0.6",
4
+ "version": "5.0.8",
5
5
  "homepage": "https://feathersjs.com",
6
6
  "main": "lib/",
7
7
  "types": "lib/",
@@ -53,28 +53,28 @@
53
53
  "access": "public"
54
54
  },
55
55
  "dependencies": {
56
- "@feathersjs/commons": "^5.0.6",
57
- "@feathersjs/errors": "^5.0.6",
58
- "@feathersjs/feathers": "^5.0.6",
56
+ "@feathersjs/commons": "^5.0.8",
57
+ "@feathersjs/errors": "^5.0.8",
58
+ "@feathersjs/feathers": "^5.0.8",
59
59
  "@feathersjs/hooks": "^0.8.1",
60
- "@feathersjs/schema": "^5.0.6",
61
- "@feathersjs/transport-commons": "^5.0.6",
60
+ "@feathersjs/schema": "^5.0.8",
61
+ "@feathersjs/transport-commons": "^5.0.8",
62
62
  "@types/jsonwebtoken": "^9.0.2",
63
- "jsonwebtoken": "^9.0.0",
63
+ "jsonwebtoken": "^9.0.1",
64
64
  "lodash": "^4.17.21",
65
65
  "long-timeout": "^0.1.1",
66
66
  "uuid": "^9.0.0"
67
67
  },
68
68
  "devDependencies": {
69
- "@feathersjs/memory": "^5.0.6",
69
+ "@feathersjs/memory": "^5.0.8",
70
70
  "@types/lodash": "^4.14.195",
71
71
  "@types/mocha": "^10.0.1",
72
- "@types/node": "^20.3.1",
72
+ "@types/node": "^20.4.2",
73
73
  "@types/uuid": "^9.0.2",
74
74
  "mocha": "^10.2.0",
75
75
  "shx": "^0.3.4",
76
76
  "ts-node": "^10.9.1",
77
- "typescript": "^5.1.3"
77
+ "typescript": "^5.1.6"
78
78
  },
79
- "gitHead": "71ac655d260fbc9aa65cd5b9a6c088f0187ace4e"
79
+ "gitHead": "414336a047a556f1986b4bb253416d5b8a973d9f"
80
80
  }
package/src/service.ts CHANGED
@@ -2,13 +2,14 @@ import merge from 'lodash/merge'
2
2
  import { NotAuthenticated } from '@feathersjs/errors'
3
3
  import '@feathersjs/transport-commons'
4
4
  import { createDebug } from '@feathersjs/commons'
5
- import { ServiceMethods, ServiceAddons } from '@feathersjs/feathers'
5
+ import { ServiceMethods } from '@feathersjs/feathers'
6
6
  import { resolveDispatch } from '@feathersjs/schema'
7
7
  import jsonwebtoken from 'jsonwebtoken'
8
8
  import { hooks } from '@feathersjs/hooks'
9
9
 
10
10
  import { AuthenticationBase, AuthenticationResult, AuthenticationRequest, AuthenticationParams } from './core'
11
11
  import { connection, event } from './hooks'
12
+ import { RealTimeConnection } from '@feathersjs/feathers'
12
13
 
13
14
  const debug = createDebug('@feathersjs/authentication/service')
14
15
 
@@ -31,9 +32,6 @@ declare module '@feathersjs/feathers/lib/declarations' {
31
32
  }
32
33
  }
33
34
 
34
- // eslint-disable-next-line @typescript-eslint/no-empty-interface
35
- export interface AuthenticationService extends ServiceAddons<AuthenticationResult, AuthenticationResult> {}
36
-
37
35
  export class AuthenticationService
38
36
  extends AuthenticationBase
39
37
  implements Partial<ServiceMethods<AuthenticationResult, AuthenticationRequest, AuthenticationParams>>
@@ -46,7 +44,7 @@ export class AuthenticationService
46
44
  remove: [resolveDispatch(), event('logout'), connection('logout')]
47
45
  })
48
46
 
49
- this.app.on('disconnect', async (connection) => {
47
+ this.app.on('disconnect', async (connection: RealTimeConnection) => {
50
48
  await this.handleConnection('disconnect', connection)
51
49
  })
52
50
 
@@ -196,8 +194,10 @@ export class AuthenticationService
196
194
  }
197
195
  }
198
196
 
199
- if (typeof this.publish === 'function') {
200
- this.publish(() => null)
197
+ const publishable = this as any
198
+
199
+ if (typeof publishable.publish === 'function') {
200
+ publishable.publish((): any => null)
201
201
  }
202
202
  }
203
203
  }