Skip to content

Commit

Permalink
Fixed the bug of unregistered types
Browse files Browse the repository at this point in the history
  • Loading branch information
mohammed-io committed May 15, 2019
1 parent 7f2f510 commit 2cb54c6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "generate-migrations-hook",
"description": "This hook is to generate voyager-only migration for laravel app",
"version": "v0.1.1beta",
"version": "v0.1.2beta",
"license": "MIT",
"homepage": "https://github.com/mohammed-io/generate-migrations-hook",
"authors": [
Expand Down
6 changes: 6 additions & 0 deletions src/templates/MigrationFileTemplate.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,15 @@ public function generate(array $config)
use Illuminate\Database\Migrations\Migration;
use TCG\Voyager\Database\DatabaseUpdater;
use TCG\Voyager\Database\Schema\SchemaManager;
use TCG\Voyager\Database\Types\Type;
class $className extends Migration
{
public function __construct()
{
Type::registerCustomPlatformTypes();
}
/**
* Run the migrations.
*
Expand Down

0 comments on commit 2cb54c6

Please sign in to comment.