Skip to content

Commit

Permalink
Reorganizes methods and properties to be alphabetical
Browse files Browse the repository at this point in the history
  • Loading branch information
craigpaul committed Sep 14, 2021
1 parent b210601 commit 52378a8
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions src/resources/wait-time.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,24 +9,30 @@ export interface WaitTimeParameters {
}

export interface WaitTimeResource {
at(location: string | number): this;
on(page: number): this;
take(limit: number): this;
at(location: string | number): this;
}

export default class WaitTime extends Conditional implements WaitTimeResource {
protected client: AxiosInstance;
protected limit: number | null;
protected location: string | number | null;
protected page: number | null;
protected limit: number | null;

constructor(client: AxiosInstance) {
super();

this.client = client;
this.limit = null;
this.location = null;
this.page = null;
this.limit = null;
}

public at(location: string | number): this {
this.location = location;

return this;
}

public async get(): Promise<any> {
Expand All @@ -48,12 +54,6 @@ export default class WaitTime extends Conditional implements WaitTimeResource {
return await this.client.get(location ? `wait-time-average/${location}` : 'wait-time-average', { params });
}

public at(location: string | number): this {
this.location = location;

return this;
}

public on(page: number): this {
this.page = page;

Expand Down

0 comments on commit 52378a8

Please sign in to comment.