File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -241,16 +241,18 @@ export class Controller<State extends Indexable = UnknownProps> {
241
241
/** Determine which keys should receive an update */
242
242
function extractKeys ( props : ControllerProps , springs : Indexable < SpringValue > ) {
243
243
const keys = new Set < AnyKey > ( )
244
- const extract = ( obj : Indexable ) =>
244
+
245
+ /** Collect keys with a defined value */
246
+ const extractDefined = ( obj : Indexable ) =>
245
247
each ( obj , ( value , key ) => {
246
248
if ( ! is . und ( value ) ) {
247
249
keys . add ( key )
248
250
}
249
251
} )
250
252
251
253
const { from, to } = props
252
- if ( is . obj ( to ) ) extract ( to )
253
- if ( from ) extract ( from )
254
+ if ( is . obj ( to ) ) extractDefined ( to )
255
+ if ( from ) extractDefined ( from )
254
256
255
257
// When neither "from" or "to" have a key with a defined value,
256
258
// return the keys for every existing spring.
You can’t perform that action at this time.
0 commit comments