Skip to content

Commit 73efc26

Browse files
committed
Remove unused method
1 parent 3e212af commit 73efc26

File tree

2 files changed

+1
-17
lines changed

2 files changed

+1
-17
lines changed

src/__tests__/checkout.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -384,7 +384,7 @@ describe("Checkout", (): void => {
384384
// });
385385

386386
test("should have missing identifier on live", async (): Promise<void> => {
387-
client.setEnvironment("LIVE");
387+
client.config.environment = "LIVE";
388388
try {
389389
const liveCheckout = new CheckoutAPI(client);
390390
await liveCheckout.PaymentsApi.payments(createPaymentsCheckoutRequest());

src/client.ts

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -79,22 +79,6 @@ class Client {
7979

8080
}
8181

82-
/**
83-
* Sets the environment and updates endpoints in the config.
84-
* @param environment - The environment ("TEST" or "LIVE").
85-
* @param liveEndpointUrlPrefix - Optional live endpoint prefix.
86-
*/
87-
public setEnvironment(environment: Environment, liveEndpointUrlPrefix?: string): void {
88-
// ensure environment is set in config
89-
this.config.environment = environment;
90-
91-
if (environment === "TEST") {
92-
this.config.marketPayEndpoint = Client.MARKETPAY_ENDPOINT_TEST;
93-
} else if (environment === "LIVE") {
94-
this.config.marketPayEndpoint = Client.MARKETPAY_ENDPOINT_LIVE;
95-
}
96-
}
97-
9882
/**
9983
* Gets the HTTP client instance, creating a default one if not set.
10084
*/

0 commit comments

Comments
 (0)