@@ -13,33 +13,33 @@ export default function Inner(patch) {
1313 this . patch = patch
1414}
1515
16- Inner . patch = function ( { origin, destiny, prop, oldValue , applyPatch } ) {
16+ Inner . patch = function ( { origin, destiny, prop, old_value , applyPatch } ) {
1717 const origin_value = origin [ prop ]
1818 if ( origin_value instanceof Inner ) {
19- destiny [ prop ] = oldValue
20- if ( isArray ( oldValue ) ) {
19+ destiny [ prop ] = old_value
20+ if ( isArray ( old_value ) ) {
2121 const patches = origin_value . patch
2222 const unpatches = { }
23- const length = oldValue . length
23+ const length = old_value . length
2424 for ( const key in patches ) {
25- const had_prop = oldValue . hasOwnProperty ( key )
26- const patched = applyPatch ( oldValue [ key ] , patches [ key ] )
25+ const had_prop = old_value . hasOwnProperty ( key )
26+ const patched = applyPatch ( old_value [ key ] , patches [ key ] )
2727 if (
28- oldValue [ key ] !== patched . result ||
28+ old_value [ key ] !== patched . result ||
2929 isPlainObject ( patches [ key ] )
3030 ) {
31- oldValue [ key ] = patched . result
31+ old_value [ key ] = patched . result
3232 unpatches [ key ] = had_prop ? patched . unpatch : Delete ( )
3333 }
3434 }
35- if ( oldValue . length !== length ) {
35+ if ( old_value . length !== length ) {
3636 unpatches . length = length
3737 }
38- // console.log({ result: oldValue , unpatches })
38+ // console.log({ result: old_value , unpatches })
3939 return new Inner ( unpatches )
4040 }
4141 }
42- return oldValue
42+ return old_value
4343}
4444
4545Inner . encode = function ( { value, encode } ) {
0 commit comments