app/views/piggybak/cart/_form.html.erb in piggybak-0.7.3 vs app/views/piggybak/cart/_form.html.erb in piggybak-0.7.4
- old
+ new
@@ -1,5 +1,5 @@
-<% if object.reflections.keys.include?(:piggybak_sellable) -%>
+<% if object.respond_to?(:piggybak_sellable) -%>
<% if object.piggybak_sellable && object.piggybak_sellable.active -%>
<% if object.piggybak_sellable.quantity > 0 || object.piggybak_sellable.unlimited_inventory -%>
<%= form_tag piggybak.cart_add_url, locals[:options] do -%>
<div id="sellable_details">
<span id="title"><%= object.piggybak_sellable.description %></span>