From 11fc7dab8bac4fee8377b3ed6c992453c7059ef2 Mon Sep 17 00:00:00 2001 From: Sean Harvey Date: Mon, 13 Jul 2009 23:11:23 +0000 Subject: [PATCH] MINOR Whitespace fixes --- code/FileSubsites.php | 8 ++++---- code/GroupSubsites.php | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/code/FileSubsites.php b/code/FileSubsites.php index 4834c27..1e20b1f 100755 --- a/code/FileSubsites.php +++ b/code/FileSubsites.php @@ -43,8 +43,8 @@ class FileSubsites extends DataObjectDecorator { // If you're querying by ID, ignore the sub-site - this is a bit ugly... if(strpos($query->where[0], ".`ID` = ") === false && strpos($query->where[0], ".ID = ") === false) { - if($context = DataObject::context_obj()) $subsiteID = (int)$context->SubsiteID; - else $subsiteID = (int)Subsite::currentSubsiteID(); + if($context = DataObject::context_obj()) $subsiteID = (int) $context->SubsiteID; + else $subsiteID = (int) Subsite::currentSubsiteID(); // The foreach is an ugly way of getting the first key :-) foreach($query->from as $tableName => $info) { @@ -56,8 +56,8 @@ class FileSubsites extends DataObjectDecorator { $query->where[] = $where; break; } - - $query->orderby = 'SubsiteID' . ($query->orderby ? ', ' : '') . $query->orderby; + + $query->orderby = 'SubsiteID' . ($query->orderby ? ', ' : '') . $query->orderby; } } diff --git a/code/GroupSubsites.php b/code/GroupSubsites.php index 22312dc..4d4d49c 100644 --- a/code/GroupSubsites.php +++ b/code/GroupSubsites.php @@ -72,8 +72,8 @@ class GroupSubsites extends DataObjectDecorator { // If you're querying by ID, ignore the sub-site - this is a bit ugly... if(!$query->where || (strpos($query->where[0], ".\"ID\" = ") === false && strpos($query->where[0], ".`ID` = ") === false && strpos($query->where[0], ".ID = ") === false)) { - if($context = DataObject::context_obj()) $subsiteID = (int)$context->SubsiteID; - else $subsiteID = (int)Subsite::currentSubsiteID(); + if($context = DataObject::context_obj()) $subsiteID = (int) $context->SubsiteID; + else $subsiteID = (int) Subsite::currentSubsiteID(); // The foreach is an ugly way of getting the first key :-) foreach($query->from as $tableName => $info) {