Skip to content

Commit

Permalink
fix: change name of public facing clients.
Browse files Browse the repository at this point in the history
Changes TurboPrivateClient and TurboPublicClient to TurboUnauthenticatedClient and TurboAuthenticatedClient
  • Loading branch information
dtfiedler committed Sep 8, 2023
1 parent bf2a054 commit 7925b99
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 6 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,6 @@ yarn-error.log

# Build files
**/*.min.js

# Any local builds
*.tgz
10 changes: 6 additions & 4 deletions src/common/turbo.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
import {
Currency,
TurboAbortSignal,
TurboAuthenticatedClientInterface,
TurboAuthenticatedPaymentServiceInterface,
TurboAuthenticatedUploadServiceInterface,
TurboBalanceResponse,
Expand All @@ -25,20 +26,21 @@ import {
TurboFiatToArResponse,
TurboFileFactory,
TurboPriceResponse,
TurboPrivateClient,
TurboPrivateClientConfiguration,
TurboPublicClient,
TurboPublicClientConfiguration,
TurboRatesResponse,
TurboSignedDataItemFactory,
TurboUnauthenticatedClientInterface,
TurboUnauthenticatedPaymentServiceInterface,
TurboUnauthenticatedUploadServiceInterface,
TurboUploadDataItemResponse,
} from '../types/index.js';
import { TurboUnauthenticatedPaymentService } from './payment.js';
import { TurboUnauthenticatedUploadService } from './upload.js';

export class TurboUnauthenticatedClient implements TurboPublicClient {
export class TurboUnauthenticatedClient
implements TurboUnauthenticatedClientInterface
{
protected readonly paymentService: TurboUnauthenticatedPaymentServiceInterface;
protected readonly uploadService: TurboUnauthenticatedUploadServiceInterface;

Expand Down Expand Up @@ -126,7 +128,7 @@ export class TurboUnauthenticatedClient implements TurboPublicClient {

export class TurboAuthenticatedClient
extends TurboUnauthenticatedClient
implements TurboPrivateClient
implements TurboAuthenticatedClientInterface
{
protected readonly paymentService: TurboAuthenticatedPaymentServiceInterface;
protected readonly uploadService: TurboAuthenticatedUploadServiceInterface;
Expand Down
4 changes: 2 additions & 2 deletions src/types/turbo.ts
Original file line number Diff line number Diff line change
Expand Up @@ -198,9 +198,9 @@ export interface TurboAuthenticatedUploadServiceInterface
}: TurboFileFactory & TurboAbortSignal): Promise<TurboUploadDataItemResponse>;
}

export interface TurboPublicClient
export interface TurboUnauthenticatedClientInterface
extends TurboUnauthenticatedPaymentServiceInterface,
TurboUnauthenticatedUploadServiceInterface {}
export interface TurboPrivateClient
export interface TurboAuthenticatedClientInterface
extends TurboAuthenticatedPaymentServiceInterface,
TurboAuthenticatedUploadServiceInterface {}

0 comments on commit 7925b99

Please sign in to comment.