Skip to content

Commit

Permalink
Removed unused variable
Browse files Browse the repository at this point in the history
  • Loading branch information
Stig Lindqvist committed Nov 10, 2013
1 parent c26a405 commit cc03490
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions code/model/Subsite.php
Original file line number Diff line number Diff line change
Expand Up @@ -413,12 +413,11 @@ static function getSubsiteIDForDomain($host = null, $checkPermissions = true) {
if(isset(self::$_cache_subsite_for_domain[$cacheKey])) return self::$_cache_subsite_for_domain[$cacheKey];

$SQL_host = Convert::raw2sql($host);
$joinFilter = self::$check_is_public ? "AND \"Subsite\".\"IsPublic\"=1" : '';
$matchingDomains = DataObject::get(
"SubsiteDomain",
"'$SQL_host' LIKE replace(\"SubsiteDomain\".\"Domain\",'*','%')",
"\"IsPrimary\" DESC"
)->innerJoin('Subsite', "\"Subsite\".\"ID\" = \"SubsiteDomain\".\"SubsiteID\" AND \"Subsite\".\"IsPublic\"=1");;
)->innerJoin('Subsite', "\"Subsite\".\"ID\" = \"SubsiteDomain\".\"SubsiteID\" AND \"Subsite\".\"IsPublic\"=1");

if($matchingDomains && $matchingDomains->Count()) {
$subsiteIDs = array_unique($matchingDomains->column('SubsiteID'));
Expand Down

0 comments on commit cc03490

Please sign in to comment.