Skip to content

Commit

Permalink
Fixes cakephp#500 . If precision is 0 command adds it anyway.
Browse files Browse the repository at this point in the history
  • Loading branch information
ajibarra committed Sep 16, 2022
1 parent b9c1eeb commit 5d8a7dd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/View/Helper/MigrationHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,7 @@ public function getColumnOption(array $options)
if (isset($columnOptions['signed']) && $columnOptions['signed'] === true) {
unset($columnOptions['signed']);
}
if (empty($columnOptions['precision'])) {
if (is_null($columnOptions['precision'])) {
unset($columnOptions['precision']);
} else {
// due to Phinx using different naming for the precision and scale to CakePHP
Expand Down

0 comments on commit 5d8a7dd

Please sign in to comment.