liferay-headless-sdk 1.0.1 → 1.0.2

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/client.js +2 -2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "liferay-headless-sdk",
3
- "version": "1.0.1",
3
+ "version": "1.0.2",
4
4
  "description": "A production-ready JavaScript SDK dynamically generated from Liferay Headless API Swagger/OpenAPI specifications.",
5
5
  "type": "module",
6
6
  "main": "./src/index.js",
package/src/client.js CHANGED
@@ -74,8 +74,8 @@ export class LiferayHeadlessClient {
74
74
  this._auth.setOAuthToken(oauthToken);
75
75
  } else if (username && password) {
76
76
  this._auth.setBasicAuth(username, password);
77
- } else if(authToken) {
78
- this._auth.setBasicAuth(username, password);
77
+ } else if (authToken) {
78
+ this._auth.setAuthToken(authToken);
79
79
  }
80
80
 
81
81
  // Auto-generate: return a Proxy that lazily triggers init on first service access