Skip to content

Commit 5a3fa3f

Browse files
Merge pull request #751 from splitio/development
Release v10.22.6
2 parents 279b0d3 + 766d19d commit 5a3fa3f

File tree

11 files changed

+437
-413
lines changed

11 files changed

+437
-413
lines changed

.github/CODEOWNERS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
* @splitio/sdk

CHANGES.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
10.22.6 (July 6, 2023)
2+
- Updated some transitive dependencies for vulnerability fixes.
3+
- Updated @splitsoftware/splitio-commons package to version 1.8.3 that includes the following bug fix:
4+
- Bugfix - The `destroy` method has been updated to immediately flag the SDK client as destroyed, to prevent access to the storage when `getTreatment` and `track` methods are called after the SDK is destroyed.
5+
16
10.22.5 (May 15, 2023)
27
- Updated @splitsoftware/splitio-commons package to version 1.8.2 that includes minor improvements.
38
- Updated terminology on the SDKs codebase to be more aligned with current standard without causing a breaking change. The core change is the term split for feature flag on things like logs and IntelliSense comments.

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ Split has built and maintains SDKs for:
6464

6565
* .NET [Github](https://github.com/splitio/dotnet-client) [Docs](https://help.split.io/hc/en-us/articles/360020240172--NET-SDK)
6666
* Android [Github](https://github.com/splitio/android-client) [Docs](https://help.split.io/hc/en-us/articles/360020343291-Android-SDK)
67+
* Angular [Github](https://github.com/splitio/angular-sdk-plugin) [Docs](https://help.split.io/hc/en-us/articles/6495326064397-Angular-utilities)
6768
* GO [Github](https://github.com/splitio/go-client) [Docs](https://help.split.io/hc/en-us/articles/360020093652-Go-SDK)
6869
* iOS [Github](https://github.com/splitio/ios-client) [Docs](https://help.split.io/hc/en-us/articles/360020401491-iOS-SDK)
6970
* Java [Github](https://github.com/splitio/java-client) [Docs](https://help.split.io/hc/en-us/articles/360020405151-Java-SDK)

package-lock.json

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

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@splitsoftware/splitio",
3-
"version": "10.22.5",
3+
"version": "10.22.6",
44
"description": "Split SDK",
55
"files": [
66
"README.md",
@@ -40,7 +40,7 @@
4040
"node": ">=6"
4141
},
4242
"dependencies": {
43-
"@splitsoftware/splitio-commons": "1.8.2",
43+
"@splitsoftware/splitio-commons": "1.8.3",
4444
"@types/google.analytics": "0.0.40",
4545
"@types/ioredis": "^4.28.0",
4646
"bloom-filters": "^3.0.0",
@@ -59,7 +59,7 @@
5959
"cross-env": "^7.0.3",
6060
"csv-streamify": "4.0.0",
6161
"eslint": "^8.0.1",
62-
"eslint-plugin-compat": "^4.0.2",
62+
"eslint-plugin-compat": "^4.1.4",
6363
"eslint-plugin-import": "^2.25.4",
6464
"fetch-mock": "^9.11.0",
6565
"karma": "^6.3.16",

src/__tests__/destroy/browser.spec.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -130,8 +130,7 @@ tape('SDK destroy for BrowserJS', async function (assert) {
130130
assert.ok(manager.names().length > 0, 'control assertion');
131131
assert.notOk(client2.track('tt', 'eventType', 2), 'After destroy, track calls return false.');
132132

133-
await client.destroy();
134-
fetchMock.restore();
133+
const destroyPromise = client.destroy();
135134

136135
assert.equal(client.getTreatment('Single_Test'), 'control', 'After destroy, getTreatment returns control for every destroyed client.');
137136
assert.deepEqual(client.getTreatments(['Single_Test']), { 'Single_Test': 'control' }, 'After destroy, getTreatments returns map of controls for every destroyed client.');
@@ -141,5 +140,8 @@ tape('SDK destroy for BrowserJS', async function (assert) {
141140
assert.equal(manager.names().length, 0, 'After the main client is destroyed, manager.names will return empty array');
142141
assert.equal(manager.split('Single_Test'), null, 'After the main client is destroyed, manager.split will return null');
143142

143+
await destroyPromise;
144+
fetchMock.restore();
145+
144146
assert.end();
145147
});

src/__tests__/destroy/node.spec.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -109,10 +109,6 @@ tape('SDK destroy for NodeJS', async function (assert) {
109109

110110
const destroyPromise = client.destroy();
111111

112-
assert.true(destroyPromise instanceof Promise, 'client.destroy() should return a promise.');
113-
114-
await destroyPromise;
115-
116112
assert.equal(client.getTreatment('ut1', 'Single_Test'), 'control', 'After destroy, getTreatment returns control.');
117113
assert.deepEqual(client.getTreatments('ut1', ['Single_Test', 'another_split']), {
118114
Single_Test: 'control', another_split: 'control'
@@ -122,5 +118,9 @@ tape('SDK destroy for NodeJS', async function (assert) {
122118
assert.equal(manager.names().length, 0, 'After destroy, manager.names returns empty array.');
123119
assert.equal(manager.split('Single_Test'), null, 'After destroy, manager.split returns null.');
124120

121+
assert.true(destroyPromise instanceof Promise, 'client.destroy() should return a promise.');
122+
123+
await destroyPromise;
124+
125125
assert.end();
126126
});

src/settings/defaults/version.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
export const packageVersion = '10.22.5';
1+
export const packageVersion = '10.22.6';

src/settings/storage/node.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { LOCALHOST_MODE, STORAGE_MEMORY, STORAGE_REDIS, CONSUMER_MODE, STANDALONE_MODE } from '@splitsoftware/splitio-commons/src/utils/constants';
22

33
export function validateStorage(settings) {
4-
let {
4+
const {
55
log,
66
mode,
77
storage: {

ts-tests/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"license": "Apache-2.0",
77
"repository": "splitio/javascript-client",
88
"dependencies": {
9-
"@types/node": "^14.18.46",
9+
"@types/node": "^14.18.52",
1010
"typescript": "^3.7.4"
1111
}
1212
}

0 commit comments

Comments
 (0)