Removed unnecessary explicit __toString() calls
authorAlexander Ebert <ebert@woltlab.com>
Sat, 12 Jan 2013 21:57:03 +0000 (22:57 +0100)
committerAlexander Ebert <ebert@woltlab.com>
Sat, 12 Jan 2013 21:57:03 +0000 (22:57 +0100)
wcfsetup/install/files/lib/data/DatabaseObjectList.class.php
wcfsetup/install/files/lib/data/style/StyleAction.class.php

index d72246bbfd6f764021e9bde63991cccf353ecbb1..6c57d8eaa7d762982be3cc06c45a21a24c852dee 100644 (file)
@@ -145,7 +145,7 @@ abstract class DatabaseObjectList implements \Countable, ITraversableObject {
                $sql = "SELECT  COUNT(*) AS count
                        FROM    ".$this->getDatabaseTableName()." ".$this->getDatabaseTableAlias()."
                        ".$this->sqlConditionJoins."
-                       ".$this->getConditionBuilder()->__toString();
+                       ".$this->getConditionBuilder();
                $statement = WCF::getDB()->prepareStatement($sql);
                $statement->execute($this->getConditionBuilder()->getParameters());
                $row = $statement->fetchArray();
@@ -160,7 +160,7 @@ abstract class DatabaseObjectList implements \Countable, ITraversableObject {
                $sql = "SELECT  ".$this->getDatabaseTableAlias().".".$this->getDatabaseTableIndexName()." AS objectID
                        FROM    ".$this->getDatabaseTableName()." ".$this->getDatabaseTableAlias()."
                                ".$this->sqlConditionJoins."
-                               ".$this->getConditionBuilder()->__toString()."
+                               ".$this->getConditionBuilder()."
                                ".(!empty($this->sqlOrderBy) ? "ORDER BY ".$this->sqlOrderBy : '');
                $statement = WCF::getDB()->prepareStatement($sql, $this->sqlLimit, $this->sqlOffset);
                $statement->execute($this->getConditionBuilder()->getParameters());
@@ -192,7 +192,7 @@ abstract class DatabaseObjectList implements \Countable, ITraversableObject {
                                        ".($this->useQualifiedShorthand ? $this->getDatabaseTableAlias().'.*' : '')."
                                FROM    ".$this->getDatabaseTableName()." ".$this->getDatabaseTableAlias()."
                                        ".$this->sqlJoins."
-                                       ".$this->getConditionBuilder()->__toString()."
+                                       ".$this->getConditionBuilder()."
                                        ".(!empty($this->sqlOrderBy) ? "ORDER BY ".$this->sqlOrderBy : '');
                        $statement = WCF::getDB()->prepareStatement($sql, $this->sqlLimit, $this->sqlOffset);
                        $statement->execute($this->getConditionBuilder()->getParameters());
index 5e78120176b42912472a8b3de1e3a48f32d749b4..5af04b76fc99ff88364a40d3e763af235a1f5ce6 100644 (file)
@@ -132,10 +132,10 @@ class StyleAction extends AbstractDatabaseObjectAction implements IToggleAction
                        $iterator = new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($dir), \RecursiveIteratorIterator::CHILD_FIRST);
                        foreach ($iterator as $path) {
                                if ($path->isDir()) {
-                                       @rmdir($path->__toString());
+                                       @rmdir($path);
                                }
                                else {
-                                       @unlink($path->__toString());
+                                       @unlink($path);
                                }
                        }