@pikku/fetch 0.8.0 → 0.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md
CHANGED
|
@@ -51,13 +51,11 @@ class CorePikkuFetch {
|
|
|
51
51
|
* @param {string} serverUrl - The server URL to be set.
|
|
52
52
|
*/
|
|
53
53
|
setServerUrl(serverUrl) {
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
this.options.serverUrl = serverUrl;
|
|
60
|
-
});
|
|
54
|
+
if (serverUrl.endsWith('/')) {
|
|
55
|
+
console.warn('Server URL should not end with a slash, removing.');
|
|
56
|
+
serverUrl = serverUrl.slice(0, -1);
|
|
57
|
+
}
|
|
58
|
+
this.options.serverUrl = serverUrl;
|
|
61
59
|
}
|
|
62
60
|
/**
|
|
63
61
|
* Sets the JWT for authorization.
|
|
@@ -39,7 +39,7 @@ export class CorePikkuFetch {
|
|
|
39
39
|
*
|
|
40
40
|
* @param {string} serverUrl - The server URL to be set.
|
|
41
41
|
*/
|
|
42
|
-
|
|
42
|
+
setServerUrl(serverUrl) {
|
|
43
43
|
if (serverUrl.endsWith('/')) {
|
|
44
44
|
console.warn('Server URL should not end with a slash, removing.');
|
|
45
45
|
serverUrl = serverUrl.slice(0, -1);
|
package/package.json
CHANGED
package/src/core-pikku-fetch.ts
CHANGED
|
@@ -64,7 +64,7 @@ export class CorePikkuFetch {
|
|
|
64
64
|
*
|
|
65
65
|
* @param {string} serverUrl - The server URL to be set.
|
|
66
66
|
*/
|
|
67
|
-
public
|
|
67
|
+
public setServerUrl(serverUrl: string): void {
|
|
68
68
|
if (serverUrl.endsWith('/')) {
|
|
69
69
|
console.warn('Server URL should not end with a slash, removing.')
|
|
70
70
|
serverUrl = serverUrl.slice(0, -1)
|