changed for spree 2.2 compatibility