diff --git a/app/tasks/migrate.php b/app/tasks/migrate.php index e9271e793..f6b47814d 100644 --- a/app/tasks/migrate.php +++ b/app/tasks/migrate.php @@ -25,7 +25,9 @@ $cli } $options = []; if (str_starts_with($version, '0.12.')) { + Console::error('--------------------'); Console::error('WARNING'); + Console::error('--------------------'); Console::warning('Migrating to Version 0.12.x introduces a major breaking change within the Database Service!'); Console::warning('Before migrating, please read about the breaking changes here:'); Console::info('https://appwrite.io/guide-to-db-migration'); @@ -41,6 +43,7 @@ $cli Console::warning('Be aware that following actions will happen during the migration:'); Console::warning('- Nested Document rules will be migrated to String attributes'); Console::warning('- Numeric rules will be migrated to float attributes'); + Console::warning('- Wildcard and Markdown rules will be converted to string attributes'); Console::info("Do you want to migrate your Database Collections?"); $options['migrateCollections'] = Console::confirm("Type 'yes' or 'no':"); @@ -51,6 +54,7 @@ $cli Console::warning('Be aware that following actions will happen during the migration:'); Console::warning('- Nested Documents will be stored as JSON values'); Console::warning('- All Numeric values will be converted to float'); + Console::warning('- All Wildcard and Markdown values will be converted to string'); Console::info("Do you want to migrate your Database Documents?"); $options['migrateDocuments'] = Console::confirm("Type 'yes' or 'no':"); } else { diff --git a/src/Appwrite/Migration/Migration.php b/src/Appwrite/Migration/Migration.php index 36bb9cad3..08effc05d 100644 --- a/src/Appwrite/Migration/Migration.php +++ b/src/Appwrite/Migration/Migration.php @@ -71,13 +71,16 @@ abstract class Migration /** * Migration constructor. * - * @param PDO $pdo + * @param PDO $db + * @param Redis|null $cache + * @param array $options + * @return void */ public function __construct(PDO $db, Redis $cache = null, array $options = []) { $this->options = $options; $this->db = $db; - if(!is_null($cache)) { + if (!is_null($cache)) { $this->cache = $cache; } } @@ -166,7 +169,7 @@ abstract class Migration * @param array $array2 * @return array */ - public function check_diff_multi(array $array1, array $array2) + public function check_diff_multi(array $array1, array $array2): array { $result = array();