Skip to content

Commit

Permalink
Fixed extra config handling so storage key will remain the same.
Browse files Browse the repository at this point in the history
  • Loading branch information
frankdejonge committed Aug 17, 2011
1 parent 62473be commit bd41f5e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion classes/cart.php
Expand Up @@ -34,6 +34,7 @@ abstract class Cart {
* Basket factory. Returns a new Cart_Basket.
*
* @param string $cart the cart identifier.
* @param array $config aditional config array
* @return object Cart_Basket instance
*/
public static function factory($cart = 'default', $config = array())
Expand All @@ -55,7 +56,7 @@ public static function factory($cart = 'default', $config = array())

$config = $config + $cart_config;
$config = $config + static::$default;
$config['storage_key'] = \Config::get('cart.storage_prefix', '').$key.\Config::get('cart.storage_suffix');
$config['storage_key'] = \Config::get('cart.storage_prefix', '').$cart.\Config::get('cart.storage_suffix');

$driver = '\\Cart_'.ucfirst($config['driver']);
if( ! class_exists($driver, true))
Expand Down

0 comments on commit bd41f5e

Please sign in to comment.