@@ -188,9 +188,9 @@ public function synchronize(
188
188
force: $ force ,
189
189
log: $ log
190
190
);
191
-
191
+
192
192
$ result = $ processResult ['result ' ];
193
-
193
+
194
194
if ($ processResult ['targetId ' ] !== null ) {
195
195
$ synchronizedTargetIds [] = $ processResult ['targetId ' ];
196
196
}
@@ -845,12 +845,12 @@ private function processSyncContract(string $synchronizationId, array $subObject
845
845
);
846
846
}
847
847
848
- // $this->synchronizationContractLogMapper->createFromArray([
849
- // 'synchronizationId' => $subContract->getSynchronizationId(),
850
- // 'synchronizationContractId' => $subContract->getId(),
851
- // 'target' => $subObjectData,
852
- // 'expires' => new DateTime('+1 day')
853
- // ]);
848
+ $ this ->synchronizationContractLogMapper ->createFromArray ([
849
+ 'synchronizationId ' => $ subContract ->getSynchronizationId (),
850
+ 'synchronizationContractId ' => $ subContract ->getId (),
851
+ 'target ' => $ subObjectData ,
852
+ 'expires ' => new DateTime ('+1 day ' )
853
+ ]);
854
854
}
855
855
856
856
/**
@@ -2059,23 +2059,23 @@ private function xmlToArray(\SimpleXMLElement $xml): array
2059
2059
* @param bool $isTest Whether this is a test run
2060
2060
* @param bool $force Whether to force synchronization regardless of changes
2061
2061
* @param SynchronizationLog $log The synchronization log
2062
- *
2062
+ *
2063
2063
* @return array Contains updated result data and the targetId ['result' => array, 'targetId' => string|null]
2064
2064
*/
2065
2065
private function processSynchronizationObject (
2066
- Synchronization $ synchronization ,
2067
- array $ object ,
2068
- array $ result ,
2069
- bool $ isTest ,
2070
- bool $ force ,
2066
+ Synchronization $ synchronization ,
2067
+ array $ object ,
2068
+ array $ result ,
2069
+ bool $ isTest ,
2070
+ bool $ force ,
2071
2071
SynchronizationLog $ log
2072
2072
): array {
2073
2073
// We can only deal with arrays (based on the source empty values or string might be returned)
2074
2074
if (is_array ($ object ) === false ) {
2075
2075
$ result ['objects ' ]['invalid ' ]++;
2076
2076
return ['result ' => $ result , 'targetId ' => null ];
2077
2077
}
2078
-
2078
+
2079
2079
$ conditionsObject = $ this ->encodeArrayKeys ($ object , '. ' , '. ' );
2080
2080
2081
2081
// Check if object adheres to conditions.
@@ -2091,7 +2091,7 @@ private function processSynchronizationObject(
2091
2091
2092
2092
// Get the synchronization contract for this object
2093
2093
$ synchronizationContract = $ this ->synchronizationContractMapper ->findSyncContractByOriginId (
2094
- synchronizationId: $ synchronization ->id ,
2094
+ synchronizationId: $ synchronization ->id ,
2095
2095
originId: $ originId
2096
2096
);
2097
2097
@@ -2111,9 +2111,9 @@ private function processSynchronizationObject(
2111
2111
);
2112
2112
2113
2113
$ synchronizationContract = $ synchronizationContractResult ['contract ' ];
2114
- $ result ['contracts ' ][] = isset ($ synchronizationContractResult ['contract ' ]['uuid ' ]) ?
2114
+ $ result ['contracts ' ][] = isset ($ synchronizationContractResult ['contract ' ]['uuid ' ]) ?
2115
2115
$ synchronizationContractResult ['contract ' ]['uuid ' ] : null ;
2116
- $ result ['logs ' ][] = isset ($ synchronizationContractResult ['log ' ]['uuid ' ]) ?
2116
+ $ result ['logs ' ][] = isset ($ synchronizationContractResult ['log ' ]['uuid ' ]) ?
2117
2117
$ synchronizationContractResult ['log ' ]['uuid ' ] : null ;
2118
2118
$ result ['objects ' ]['created ' ]++;
2119
2119
} else {
@@ -2128,15 +2128,15 @@ private function processSynchronizationObject(
2128
2128
);
2129
2129
2130
2130
$ synchronizationContract = $ synchronizationContractResult ['contract ' ];
2131
- $ result ['contracts ' ][] = isset ($ synchronizationContractResult ['contract ' ]['uuid ' ]) === true ?
2131
+ $ result ['contracts ' ][] = isset ($ synchronizationContractResult ['contract ' ]['uuid ' ]) === true ?
2132
2132
$ synchronizationContractResult ['contract ' ]['uuid ' ] : null ;
2133
- $ result ['logs ' ][] = isset ($ synchronizationContractResult ['log ' ]['uuid ' ]) === true ?
2133
+ $ result ['logs ' ][] = isset ($ synchronizationContractResult ['log ' ]['uuid ' ]) === true ?
2134
2134
$ synchronizationContractResult ['log ' ]['uuid ' ] : null ;
2135
2135
$ result ['objects ' ]['updated ' ]++;
2136
2136
}
2137
2137
2138
2138
$ targetId = $ synchronizationContract ['targetId ' ] ?? null ;
2139
-
2139
+
2140
2140
return ['result ' => $ result , 'targetId ' => $ targetId ];
2141
2141
}
2142
2142
0 commit comments