-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dead code cleanup #91
Changes from 13 commits
17c22e1
30f0195
62876eb
78f2a20
a8b9f89
750036e
196cbef
b672e95
24e9573
5dc01e7
5cfc064
ad22cc4
7207664
e35cf23
897b635
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -123,8 +123,7 @@ public function getTables() | |
*/ | ||
public function getTable($tableName) | ||
{ | ||
$tableName = strtolower($tableName); | ||
if (!isset($this->_tables[$tableName])) { | ||
if (false === $this->hasTable($tableName)) { | ||
throw SchemaException::tableDoesNotExist($tableName); | ||
} | ||
|
||
|
@@ -214,7 +213,10 @@ public function renameTable($oldTableName, $newTableName) | |
public function dropTable($tableName) | ||
{ | ||
$tableName = strtolower($tableName); | ||
$table = $this->getTable($tableName); | ||
if (false === $this->hasTable($tableName)) { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yes I'm for this syntax but I don't know the CS for Doctrine. Do they use ! or false === ? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. they use There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Hum ok good to know :) |
||
throw SchemaException::tableDoesNotExist($tableName); | ||
} | ||
|
||
unset($this->_tables[$tableName]); | ||
return $this; | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks