Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions packages/optimizely-sdk/CHANGELOG.MD
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## [Unreleased]
### Bug fixes

- In `Optimizely` class, use `any` type when assigning the return value of `setTimeout`. This is to allow it to type check regardless of whether it uses the browser or Node version of `setTimeout` ([PR #623](https://github.com/optimizely/javascript-sdk/pull/623)), ([Issue #622](https://github.com/optimizely/javascript-sdk/issues/622))

## [4.4.1] - November 5, 2020

Expand Down
4 changes: 3 additions & 1 deletion packages/optimizely-sdk/lib/optimizely/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,9 @@ export default class Optimizely {
private isOptimizelyConfigValid: boolean;
private disposeOnUpdate: (() => void ) | null;
private readyPromise: Promise<{ success: boolean; reason?: string }>;
private readyTimeouts: { [key: string]: {readyTimeout: number; onClose:() => void} };
// readyTimeout is specified as any to make this work in both browser & Node
// eslint-disable-next-line @typescript-eslint/no-explicit-any
private readyTimeouts: { [key: string]: {readyTimeout: any; onClose:() => void} };
private nextReadyTimeoutId: number;
private clientEngine: string;
private clientVersion: string;
Expand Down