Skip to content

Commit

Permalink
Merge pull request #90 from kamilszewczyk/patch-1
Browse files Browse the repository at this point in the history
Fix for product urls with trailing slashes
  • Loading branch information
adampmoss authored Dec 18, 2016
2 parents 52e35b6 + 31d3776 commit 82154d9
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions app/code/community/Creare/CreareSeoCore/Helper/Data.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ public function getDiscontinuedProductUrl($product)
$cats = $product->getCategoryIds();
if (is_array($cats) && count($cats) > 1) {
$cat = Mage::getModel('catalog/category')->load( $cats[0] );
return $cat->getUrlPath();
return Mage::getUrl($cat->getUrlPath());
} else {
$cat = Mage::getModel('catalog/category')->load( $cats );
return $cat->getUrlPath();
return Mage::getUrl($cat->getUrlPath());
}
}

Expand Down Expand Up @@ -201,4 +201,4 @@ public function getProductStartingprice($product)
return $product->getFinalPrice();
}

}
}

0 comments on commit 82154d9

Please sign in to comment.