From cfeaf7614c62bc0d6db79cbfd871fe2d1b036ddb Mon Sep 17 00:00:00 2001 From: samreid Date: Fri, 2 Oct 2020 14:05:46 -0600 Subject: [PATCH] Migrate from ObservableArray => createObservableArray (Proxy), see https://github.com/phetsims/axon/issues/336 --- js/common/model/DensityBuoyancyModel.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/js/common/model/DensityBuoyancyModel.js b/js/common/model/DensityBuoyancyModel.js index 5a9e8977..a44c00aa 100644 --- a/js/common/model/DensityBuoyancyModel.js +++ b/js/common/model/DensityBuoyancyModel.js @@ -8,7 +8,7 @@ import BooleanProperty from '../../../../axon/js/BooleanProperty.js'; import DerivedProperty from '../../../../axon/js/DerivedProperty.js'; -import ObservableArray from '../../../../axon/js/ObservableArray.js'; +import createObservableArray from '../../../../axon/js/createObservableArray.js'; import Property from '../../../../axon/js/Property.js'; import Bounds3 from '../../../../dot/js/Bounds3.js'; import Vector2 from '../../../../dot/js/Vector2.js'; @@ -129,7 +129,7 @@ class DensityBuoyancyModel { this.engine.addBody( this.barrierBody ); // @public {ObservableArray.} - this.masses = new ObservableArray(); + this.masses = createObservableArray(); this.masses.addItemAddedListener( mass => { this.engine.addBody( mass.body ); } );