railsdog / spree-multi-domain

Multiple Spree stores on different domains - single unified backed for processing orders
http://railsdog.com
46 stars 233 forks source link

robust handling of nil default? #4

Open paulcc opened 14 years ago

paulcc commented 14 years ago

The code doesn't handle a nil value for @current_store, eg when there's no default store

What do you think to adding relevant protection?

[Rationale: I've got a site where there's going to be a high number of stores (hundreds, perhaps!), with the ability to disable some of these, plus we want a central 'admin' site. I've set the latter up as what takes over when @current_store is nil (ie vanilla spree, really) because I wasn't keen on having this as a store. Would you have done this as a store? or do you think it's valid to side-step the mechanisms?]