@@ -95,7 +95,7 @@ const defaultMethods = {
9595 method : ( input , context , above , engine ) => {
9696 if ( ! Array . isArray ( input ) ) throw new InvalidControlInput ( input )
9797
98- if ( input . length === 1 ) return ( engine . fallback || engine ) . run ( input [ 0 ] , context , { above } )
98+ if ( input . length === 1 ) return engine . run ( input [ 0 ] , context , { above } )
9999 if ( input . length < 2 ) return null
100100
101101 input = [ ...input ]
@@ -109,13 +109,13 @@ const defaultMethods = {
109109 const check = input . shift ( )
110110 const onTrue = input . shift ( )
111111
112- const test = ( engine . fallback || engine ) . run ( check , context , { above } )
112+ const test = engine . run ( check , context , { above } )
113113
114114 // if the condition is true, run the true branch
115- if ( engine . truthy ( test ) ) return ( engine . fallback || engine ) . run ( onTrue , context , { above } )
115+ if ( engine . truthy ( test ) ) return engine . run ( onTrue , context , { above } )
116116 }
117117
118- return ( engine . fallback || engine ) . run ( onFalse , context , { above } )
118+ return engine . run ( onFalse , context , { above } )
119119 } ,
120120 [ Sync ] : ( data , buildState ) => isSyncDeep ( data , buildState . engine , buildState ) ,
121121 deterministic : ( data , buildState ) => {
@@ -330,15 +330,15 @@ const defaultMethods = {
330330 method : ( input , context , above , engine ) => {
331331 if ( ! Array . isArray ( input ) ) throw new InvalidControlInput ( input )
332332 let [ selector , mapper , defaultValue ] = input
333- defaultValue = ( engine . fallback || engine ) . run ( defaultValue , context , {
333+ defaultValue = engine . run ( defaultValue , context , {
334334 above
335335 } )
336336 selector =
337- ( engine . fallback || engine ) . run ( selector , context , {
337+ engine . run ( selector , context , {
338338 above
339339 } ) || [ ]
340340 const func = ( accumulator , current ) => {
341- return ( engine . fallback || engine ) . run (
341+ return engine . run (
342342 mapper ,
343343 {
344344 accumulator,
@@ -398,8 +398,8 @@ const defaultMethods = {
398398 [ Sync ] : ( data , buildState ) => isSyncDeep ( data , buildState . engine , buildState ) ,
399399 method : ( args , context , above , engine ) => {
400400 if ( ! Array . isArray ( args ) ) throw new Error ( 'Data for pipe must be an array' )
401- let answer = ( engine . fallback || engine ) . run ( args [ 0 ] , context , { above : [ args , context , ...above ] } )
402- for ( let i = 1 ; i < args . length ; i ++ ) answer = ( engine . fallback || engine ) . run ( args [ i ] , answer , { above : [ args , context , ...above ] } )
401+ let answer = engine . run ( args [ 0 ] , context , { above : [ args , context , ...above ] } )
402+ for ( let i = 1 ; i < args . length ; i ++ ) answer = engine . run ( args [ i ] , answer , { above : [ args , context , ...above ] } )
403403 return answer
404404 } ,
405405 asyncMethod : async ( args , context , above , engine ) => {
@@ -428,7 +428,7 @@ const defaultMethods = {
428428 const item = object [ key ]
429429 Object . defineProperty ( accumulator , key , {
430430 enumerable : true ,
431- value : ( engine . fallback || engine ) . run ( item , context , { above } )
431+ value : engine . run ( item , context , { above } )
432432 } )
433433 return accumulator
434434 } , { } )
@@ -493,12 +493,12 @@ function createArrayIterativeMethod (name, useTruthy = false) {
493493 if ( ! Array . isArray ( input ) ) throw new InvalidControlInput ( input )
494494 let [ selector , mapper ] = input
495495 selector =
496- ( engine . fallback || engine ) . run ( selector , context , {
496+ engine . run ( selector , context , {
497497 above
498498 } ) || [ ]
499499
500500 return selector [ name ] ( ( i , index ) => {
501- const result = ( engine . fallback || engine ) . run ( mapper , i , {
501+ const result = engine . run ( mapper , i , {
502502 above : [ { item : selector , index } , context , ...above ]
503503 } )
504504 return useTruthy ? engine . truthy ( result ) : result
0 commit comments