diff --git a/CHANGELOG.md b/CHANGELOG.md index 422ffdb..ac78ca5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Flexisip Account Manager Changelog +v1.6.8 +--- +- Fix FLEXIAPI-375 Fix VcardsStorage table UUID size, recover the UUID from the stored vCard + v1.6.7 --- - Fix FLEXIAPI-367 Bump laravel-redis-sentinel dependency to support Redis 6 diff --git a/flexiapi/database/migrations/2025_08_27_142250_change_uuid_column_size_vcards_storage_table.php b/flexiapi/database/migrations/2025_08_27_142250_change_uuid_column_size_vcards_storage_table.php new file mode 100644 index 0000000..294ed59 --- /dev/null +++ b/flexiapi/database/migrations/2025_08_27_142250_change_uuid_column_size_vcards_storage_table.php @@ -0,0 +1,30 @@ +string('uuid', 45)->change(); + }); + + foreach (VcardStorage::all() as $vcardStorage) { + $vcard = VObject\Reader::read($vcardStorage->vcard); + $vcardStorage->uuid = $vcard->UID; + $vcardStorage->save(); + } + } + + public function down(): void + { + Schema::table('vcards_storage', function (Blueprint $table) { + $table->string('uuid', 36)->change(); + }); + } +};