Skip to content

Commit 0c24f54

Browse files
committed
Update TableSchema.php
1 parent 1d213b1 commit 0c24f54

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/Schema/TableSchema.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ public function schemaFromCache(): ?array
6464
*/
6565
public function primaryKeyFromCache(): ?string
6666
{
67-
return $this->schemaFromCache()['primaryKey'];
67+
return $this->schemaFromCache()['primaryKey'] ?? null;
6868
}
6969

7070
/**
@@ -73,7 +73,7 @@ public function primaryKeyFromCache(): ?string
7373
*/
7474
public function columnSchemasFromCache(): ?array
7575
{
76-
return $this->schemaFromCache()['columns'];
76+
return $this->schemaFromCache()['columns'] ?? null;
7777
}
7878

7979
/**
@@ -82,7 +82,7 @@ public function columnSchemasFromCache(): ?array
8282
*/
8383
public function foreignKeysFromCache(): ?array
8484
{
85-
return $this->schemaFromCache()['foreignKeys'];
85+
return $this->schemaFromCache()['foreignKeys'] ?? null;
8686
}
8787

8888
/**

0 commit comments

Comments
 (0)