Skip to content

Commit

Permalink
remove improvement
Browse files Browse the repository at this point in the history
  • Loading branch information
KingSora committed Jun 10, 2024
1 parent 285a939 commit 140c253
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/overlayscrollbars/src/setups/setups.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ export const createSetups = (
onUpdated: (updateInfo: SetupsUpdateInfo, updateHints: SetupsUpdateHints) => void,
onScroll: (scrollEvent: Event) => void
): Setups => {
let cacheInitialized = false;
let cacheAndOptionsInitialized = false;
const getCurrentOption = createOptionCheck(options, {});
const [
structureSetupCreate,
Expand Down Expand Up @@ -128,7 +128,7 @@ export const createSetups = (
} = updateInfo;

const _changedOptions = rawChangedOptions || {};
const _force = !!rawForce || !cacheInitialized;
const _force = !!rawForce || !cacheAndOptionsInitialized;
const baseUpdateInfoObj: SetupUpdateInfo = {
_checkOption: createOptionCheck(options, _changedOptions, _force),
_changedOptions,
Expand Down Expand Up @@ -167,7 +167,7 @@ export const createSetups = (
const changed =
truthyObserversHints || truthyStructureHints || !isEmptyObject(_changedOptions) || _force;

cacheInitialized = true;
cacheAndOptionsInitialized = true;

changed &&
onUpdated(updateInfo, {
Expand Down

0 comments on commit 140c253

Please sign in to comment.