Skip to content

Commit

Permalink
[-] CORE : fixed bug #PSCFV-6555 - Custom theme not working properly …
Browse files Browse the repository at this point in the history
…with image size
  • Loading branch information
vAugagneur committed Jan 14, 2013
1 parent 2c85555 commit 60260c4
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion classes/ImageType.php
Expand Up @@ -143,13 +143,16 @@ public static function getFormatedName($name)
{
$theme_name = Context::getContext()->shop->theme_name;
$name_without_theme_name = str_replace(array('_'.$theme_name, $theme_name.'_'), '', $name);

//check if the theme name is already in $name if yes only return $name
if (strstr($name, $theme_name) && self::getByNameNType($name))
return $name;
else if (self::getByNameNType($name_without_theme_name.'_'.$theme_name))
return $name_without_theme_name.'_'.$theme_name;
else
else if (self::getByNameNType($theme_name.'_'.$name_without_theme_name))
return $theme_name.'_'.$name_without_theme_name;
else
return $name_without_theme_name;
}

}

0 comments on commit 60260c4

Please sign in to comment.