File tree Expand file tree Collapse file tree 1 file changed +14
-2
lines changed
wcfsetup/install/files/lib/system/condition/type Expand file tree Collapse file tree 1 file changed +14
-2
lines changed Original file line number Diff line number Diff line change 1111interface IMigrateConditionType
1212{
1313 /**
14- * Converts the old condition structure to the new one. All migrated values must be removed from the `$conditionData` array.
14+ * Migrates old condition data to the new condition format by removing all successfully migrated entries from the `$conditionData`
15+ * and returns a list of condition-data in the new structure. The remaining entries are assumed to be unprocessed and are handled
16+ * by other condition types and must remain untouched.
17+ *
18+ * Note:
19+ * - Remove entries that you have successfully migrated.
20+ * - Leave unrecognized or unsupported entries untouched.
21+ * - If no data can be migrated, return an empty array.
22+ *
23+ * This allows `ConditionHandler::migrateConditionData()` to check whether all data has been migrated correctly and completely.
1524 *
1625 * @param array<string, mixed> $conditionData
1726 *
18- * @return array{identifier: string, value: mixed}[]
27+ * @return list< array{identifier: string, value: mixed}>
1928 */
2029 public function migrateConditionData (array &$ conditionData ): array ;
2130
31+ /**
32+ * Returns `true` if the method `migrateConditionData()` can migrate data for the given `$objectType` and `false` otherwise.
33+ */
2234 public function canMigrateConditionData (string $ objectType ): bool ;
2335}
You can’t perform that action at this time.
0 commit comments