Skip to content

Commit

Permalink
fixup! fix imigration type hints
Browse files Browse the repository at this point in the history
  • Loading branch information
miaulalala committed Feb 20, 2023
1 parent 6e9e6a0 commit acf9c4a
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 17 deletions.
12 changes: 6 additions & 6 deletions core/Command/Db/Migrations/GenerateCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -77,17 +77,17 @@ class {{classname}} extends SimpleMigrationStep {
/**
* @param IOutput $output
* @param Closure(): ISchemaWrapper $schemaClosure
* @psalm-param Closure $schemaClosure
* @param Closure $schemaClosure
* @psalm-param Closure(): ISchemaWrapper $schemaClosure
* @param array $options
*/
public function preSchemaChange(IOutput $output, Closure $schemaClosure, array $options) {
}
/**
* @param IOutput $output
* @param Closure(): ISchemaWrapper $schemaClosure
* @psalm-param Closure $schemaClosure
* @param Closure $schemaClosure
* @psalm-param Closure(): ISchemaWrapper $schemaClosure
* @param array $options
* @return null|ISchemaWrapper
*/
Expand All @@ -97,8 +97,8 @@ public function changeSchema(IOutput $output, Closure $schemaClosure, array $opt
/**
* @param IOutput $output
* @param Closure(): ISchemaWrapper $schemaClosure
* @psalm-param Closure $schemaClosure
* @param Closure $schemaClosure
* @psalm-param Closure(): ISchemaWrapper $schemaClosure
* @param array $options
*/
public function postSchemaChange(IOutput $output, Closure $schemaClosure, array $options): void {
Expand Down
16 changes: 8 additions & 8 deletions lib/public/Migration/IMigrationStep.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,15 @@
*/
interface IMigrationStep {
/**
* Human readable name of the migration step
* Human-readable name of the migration step
*
* @return string
* @since 14.0.0
*/
public function name(): string;

/**
* Human readable description of the migration steps
* Human-readable description of the migration steps
*
* @return string
* @since 14.0.0
Expand All @@ -52,17 +52,17 @@ public function description(): string;

/**
* @param IOutput $output
* @param Closure(): ISchemaWrapper $schemaClosure
* @psalm-param Closure $schemaClosure
* @param Closure $schemaClosure
* @psalm-param Closure(): ISchemaWrapper $schemaClosure
* @param array $options
* @since 13.0.0
*/
public function preSchemaChange(IOutput $output, Closure $schemaClosure, array $options);

/**
* @param IOutput $output
* @param Closure(): ISchemaWrapper $schemaClosure
* @psalm-param Closure $schemaClosure
* @param Closure $schemaClosure
* @psalm-param Closure(): ISchemaWrapper $schemaClosure
* @param array $options
* @return null|ISchemaWrapper
* @since 13.0.0
Expand All @@ -71,8 +71,8 @@ public function changeSchema(IOutput $output, Closure $schemaClosure, array $opt

/**
* @param IOutput $output
* @param Closure(): ISchemaWrapper $schemaClosure
* @psalm-param Closure $schemaClosure
* @param Closure $schemaClosure
* @psalm-param Closure(): ISchemaWrapper $schemaClosure
* @param array $options
* @since 13.0.0
*/
Expand Down
16 changes: 13 additions & 3 deletions lib/public/Migration/SimpleMigrationStep.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,15 +56,22 @@ public function description(): string {
}

/**
* {@inheritDoc}
* @param IOutput $output
* @param Closure $schemaClosure
* @psalm-param Closure(): ISchemaWrapper $schemaClosure
* @param array $options
*
* @since 13.0.0
*/
public function preSchemaChange(IOutput $output, Closure $schemaClosure, array $options) {
}

/**
* {@inheritDoc}
* @param IOutput $output
* @param Closure $schemaClosure
* @psalm-param Closure(): ISchemaWrapper $schemaClosure
* @param array $options
* @return null|ISchemaWrapper
*
* @since 13.0.0
*/
Expand All @@ -73,7 +80,10 @@ public function changeSchema(IOutput $output, Closure $schemaClosure, array $opt
}

/**
* {@inheritDoc}
* @param IOutput $output
* @param Closure $schemaClosure
* @psalm-param Closure(): ISchemaWrapper $schemaClosure
* @param array $options
*
* @since 13.0.0
*/
Expand Down

0 comments on commit acf9c4a

Please sign in to comment.