diff --git a/src/Classes/AbstractPostgresSchemaStateProxy.php b/src/Classes/AbstractPostgresSchemaStateProxy.php index 0bd4d1b..ea1cf8d 100644 --- a/src/Classes/AbstractPostgresSchemaStateProxy.php +++ b/src/Classes/AbstractPostgresSchemaStateProxy.php @@ -11,9 +11,8 @@ */ abstract class AbstractPostgresSchemaStateProxy extends PostgresSchemaState { - public function __construct(Connection $connection, protected PostgresSchemaState $schemaState, protected Protector $protector) + public function __construct(protected PostgresSchemaState $schemaState, protected Protector $protector) { - parent::__construct($connection); } /** diff --git a/src/Classes/PostgresSchemaStateProxy.php b/src/Classes/PostgresSchemaStateProxy.php index 24e746f..17f1f9d 100644 --- a/src/Classes/PostgresSchemaStateProxy.php +++ b/src/Classes/PostgresSchemaStateProxy.php @@ -16,10 +16,10 @@ class PostgresSchemaStateProxy extends AbstractPostgresSchemaStateProxy */ public function dump(Connection $connection, $path) { - $this->makeProcess($this->baseDumpCommand() . ' > ' . $path) + $this->schemaState->makeProcess($this->baseDumpCommand() . ' > ' . $path) ->mustRun( - $this->output, - array_merge($this->baseVariables($this->connection->getConfig() + $this->schemaState->output, + array_merge($this->baseVariables($this->schemaState->connection->getConfig() ), [ 'LARAVEL_LOAD_PATH' => $path, ])); @@ -32,7 +32,7 @@ protected function getBaseDumpArguments(): array ...array_keys(array_filter($this->getConditionalParameters())), ]; } - + public function getConditionalParameters(): array { return [