Skip to content

Commit

Permalink
fix: cannot install without prefix (#4001)
Browse files Browse the repository at this point in the history
  • Loading branch information
luceos authored Sep 20, 2024
1 parent e1a77fd commit d3144ee
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion framework/core/src/Database/Migrator.php
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ public function installFromSchema(string $path, string $driver): bool

$statement = str_replace(
'db_prefix_',
$this->connection->getTablePrefix(),
$this->connection->getTablePrefix() ?? '',
$statement
);
$this->connection->statement($statement);
Expand Down
2 changes: 1 addition & 1 deletion framework/core/src/Install/DatabaseConfig.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public function __construct(
private string $database,
private readonly ?string $username,
private readonly ?string $password,
private readonly string $prefix
private readonly ?string $prefix
) {
$this->validate();
}
Expand Down

0 comments on commit d3144ee

Please sign in to comment.