Skip to content

Commit 4d390e3

Browse files
authored
Merge branch 'development' into version5
2 parents a4f5485 + 26e65aa commit 4d390e3

4 files changed

Lines changed: 59 additions & 53 deletions

File tree

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@
33
Breaking: Cache persistence is now a separate plugin. When using a cache policy other than `IGNORE_CACHE`, you must pass `cacheOptions.persistenceStore`. Install `@contentstack/persistence-plugin` and use `new PersistenceStore({ ... })` as the store. The SDK no longer bundles persistence code or accepts `storeType` in `cacheOptions`.
44
Enhancement: SDK defines only the `PersistenceStore` interface (getItem/setItem); full implementation lives in the plugin for a lighter core package.
55

6+
### Version: 4.11.1
7+
#### Date: Feb-09-2026
8+
Fix: Fix security issues
9+
610
### Version: 4.11.0
711
#### Date: Jan-19-2026
812
Enhancement: Integrated getContentstackEndpoint method of Utils SDK for endpoint selection

package-lock.json

Lines changed: 45 additions & 45 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,8 @@
4747
"prerelease": "npm run test:all && npm run validate:all"
4848
},
4949
"dependencies": {
50-
"@contentstack/core": "^1.3.6",
51-
"@contentstack/utils": "^1.6.3",
50+
"@contentstack/core": "^1.3.9",
51+
"@contentstack/utils": "^1.7.0",
5252
"axios": "^1.13.1",
5353
"humps": "^2.0.1"
5454
},

test/api/locale-fallback-chain.spec.ts

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -146,9 +146,10 @@ describe('Locale Fallback Chain Tests', () => {
146146
locale: result.locale
147147
});
148148
} catch (error: any) {
149-
if (error.status === 422) {
150-
console.log('⚠️ API returned 422 for non-existent locale (expected behavior)');
151-
expect(error.status).toBe(422);
149+
// API can return 422, 400, or 141 for invalid/non-existent locale
150+
if (error.status === 422 || error.status === 400 || error.status === 141) {
151+
console.log(`⚠️ API returned ${error.status} for non-existent locale (expected behavior)`);
152+
expect([422, 400, 141]).toContain(error.status);
152153
} else {
153154
throw error;
154155
}
@@ -346,9 +347,10 @@ describe('Locale Fallback Chain Tests', () => {
346347
hasContent: !!result.title
347348
});
348349
} catch (error: any) {
349-
if (error.status === 422) {
350-
console.log('⚠️ API rejected invalid locale format (expected)');
351-
expect(error.status).toBe(422);
350+
// API can return 422, 400, or 141 for invalid locale format
351+
if (error.status === 422 || error.status === 400 || error.status === 141) {
352+
console.log(`⚠️ API rejected invalid locale format with status ${error.status} (expected)`);
353+
expect([422, 400, 141]).toContain(error.status);
352354
} else {
353355
throw error;
354356
}

0 commit comments

Comments
 (0)