@@ -1600,8 +1600,8 @@ public function createCollection(string $id, array $attributes = [], array $inde
16001600 if ($ created ) {
16011601 try {
16021602 $ this ->cleanupCollection ($ id );
1603- } catch (\Throwable $ rollbackError ) {
1604- Console::error ("Failed to rollback collection ' {$ id }': " . $ rollbackError ->getMessage ());
1603+ } catch (\Throwable $ e ) {
1604+ Console::error ("Failed to rollback collection ' {$ id }': " . $ e ->getMessage ());
16051605 }
16061606 }
16071607 throw new DatabaseException ("Failed to create collection metadata for ' {$ id }': " . $ e ->getMessage (), previous: $ e );
@@ -3250,7 +3250,7 @@ public function createRelationship(
32503250
32513251 $ this ->checkAttribute ($ collection , $ relationship );
32523252 $ this ->checkAttribute ($ relatedCollection , $ twoWayRelationship );
3253-
3253+
32543254 $ junctionCollection = null ;
32553255 if ($ type === self ::RELATION_MANY_TO_MANY ) {
32563256 $ junctionCollection = '_ ' . $ collection ->getSequence () . '_ ' . $ relatedCollection ->getSequence ();
@@ -9124,9 +9124,9 @@ private function updateMetadata(
91249124 // Regular mode: rollback throws on failure
91259125 try {
91269126 $ rollbackOperation ();
9127- } catch (\Throwable $ e ) {
9127+ } catch (\Throwable $ ex ) {
91289128 throw new DatabaseException (
9129- "Failed to persist metadata after retries and cleanup failed for {$ operationDescription }: " . $ e ->getMessage () . ' | Cleanup error: ' . $ rollbackException ->getMessage (),
9129+ "Failed to persist metadata after retries and cleanup failed for {$ operationDescription }: " . $ ex ->getMessage () . ' | Cleanup error: ' . $ e ->getMessage (),
91309130 previous: $ e
91319131 );
91329132 }
0 commit comments