Skip to content

Commit

Permalink
Fixed error on creating model in Doctrine
Browse files Browse the repository at this point in the history
  • Loading branch information
rougin committed Jun 22, 2015
1 parent 749d436 commit 5aaae84
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
6 changes: 4 additions & 2 deletions src/Doctrine/CreateModelCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,8 @@ public function execute()
'[mutators]',
'[singular]',
'[firstLetter]',
'[model]'
'[model]',
'[table]'
);

$replace = array(
Expand All @@ -186,7 +187,8 @@ public function execute()
rtrim($mutators),
$name,
substr($this->_input->getArgument('name'), 0, 1),
ucfirst($name)
ucfirst($name),
$this->_input->getArgument('name')
);

$model = str_replace($search, $replace, $model);
Expand Down
2 changes: 1 addition & 1 deletion src/Doctrine/Templates/Model.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
/**
* @Entity
* @Table(
* name="[singular]",
* name="[table]",
* indexes={
* [indexes]
* }
Expand Down

0 comments on commit 5aaae84

Please sign in to comment.