8000 fix: Typing updates by vonagam · Pull Request #1580 · feathersjs/feathers · GitHub
[go: up one dir, main page]

Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions packages/authentication-client/src/core.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { NotAuthenticated, FeathersError } from '@feathersjs/errors';
import { Application } from '@feathersjs/feathers';
import { Application, Params } from '@feathersjs/feathers';
import { AuthenticationRequest, AuthenticationResult } from '@feathersjs/authentication';
import { Storage, StorageWrapper } from './storage';

Expand Down Expand Up @@ -149,12 +149,12 @@ export class AuthenticationClient {
return authPromise;
}

authenticate (authentication: AuthenticationRequest): Promise<AuthenticationResult> {
authenticate (authentication: AuthenticationRequest, params?: Params): Promise<AuthenticationResult> {
if (!authentication) {
return this.reAuthenticate();
}

const promise = this.service.create(authentication)
const promise = this.service.create(authentication, params)
.then((authResult: AuthenticationResult) => {
const { accessToken } = authResult;

Expand Down
3 changes: 1 addition & 2 deletions packages/primus/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ declare const configurePrimus: FeathersPrimus;
export = configurePrimus;

interface FeathersPrimus {
(options: any, callback?: (primus: any) => void): () => void;
readonly SOCKET_KEY: unique symbol;
(options?: any, callback?: (primus: any) => void): (app: any) => void;
default: FeathersPrimus;
}
6 changes: 3 additions & 3 deletions packages/socketio/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ declare const socketio: FeathersSocketIO;
export = socketio;

interface FeathersSocketIO {
(callback?: (io: io.Server) => void): () => void;
(options: number | io.ServerOptions, callback?: (io: io.Server) => void): () => void;
(port: number, options?: io.ServerOptions, callback?: (io: io.Server) => void): () => void;
(callback?: (io: io.Server) => void): (app: any) => void;
(options: number | io.ServerOptions, callback?: (io: io.Server) => void): (app: any) => void;
(port: number, options?: io.ServerOptions, callback?: (io: io.Server) => void): (app: any) => void;
default: FeathersSocketIO;
}
0