summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDan Ungureanu <udan1107@gmail.com>2015-08-05 11:52:32 +0300
committerDan Ungureanu <udan1107@gmail.com>2015-08-05 11:52:32 +0300
commit33b5d2657f2cb62b54cce7cabc3a7bf1a316d348 (patch)
tree695fbe81fd9247c57241d067bcdccb42c85fd495 /src
parentc4f7b223db8229970b92063f800e160de6c5d359 (diff)
downloadsql-parser-33b5d2657f2cb62b54cce7cabc3a7bf1a316d348.zip
sql-parser-33b5d2657f2cb62b54cce7cabc3a7bf1a316d348.tar.gz
sql-parser-33b5d2657f2cb62b54cce7cabc3a7bf1a316d348.tar.bz2
Fixed some of Scrutinizer's issues.
Diffstat (limited to 'src')
-rw-r--r--src/Context.php4
-rw-r--r--src/Utils/Formatter.php2
2 files changed, 1 insertions, 5 deletions
diff --git a/src/Context.php b/src/Context.php
index d044038..c52cbcf 100644
--- a/src/Context.php
+++ b/src/Context.php
@@ -416,10 +416,6 @@ abstract class Context
*/
public static function load($context = '')
{
- /**
- * @var Context $context
- */
-
if (empty($context)) {
$context = self::$defaultContext;
}
diff --git a/src/Utils/Formatter.php b/src/Utils/Formatter.php
index 5d590c3..dc8c3af 100644
--- a/src/Utils/Formatter.php
+++ b/src/Utils/Formatter.php
@@ -277,7 +277,7 @@ class Formatter
if ($prev !== null) {
// Checking if a new clause started.
- if (static::isClause($prev)) {
+ if (static::isClause($prev) !== false) {
$lastClause = $prev->value;
$formattedOptions = false;
}