delivery-sdk-net icon indicating copy to clipboard operation
delivery-sdk-net copied to clipboard

Make WithCustomEndpoint tolerant for missing trailing slash

Open JiriKovar opened this issue 2 years ago • 2 comments

Motivation

In the unit tests in DeliveryOptionsBuilderTests we don't use trailing slashed for custom endpoints, but without a trailing slash, the URL is constructed incorrectly. Which makes it confusing and the error messages are not great enough to explain what was wrong, so you need to debug the issue to figure out what is wrong, which is tedious.

Proposed solution

In our internal code, we are tolerant to missing trailing slashes when building a URL. We should provide the customers of our SDKs with the same luxury.

Additional context

I have personally misguided a customer in an intercom conversation to use the custom domain, because I took an example from the unit tests, then we spent some time sending messages back and forth to figure out what was wrong and this improvement would probably take less time then we have spent on it.

JiriKovar avatar Jul 11 '22 21:07 JiriKovar

Hi @JiriKovar, thanks for the suggestion. We will take it as possible minor improvement.

MiroKentico avatar Jul 18 '22 10:07 MiroKentico

Related t #268

Simply007 avatar Jun 29 '23 08:06 Simply007