Skip to content

armgit / spree

Public Imported from GitHub
0

Open Source Platform for DTC, B2B Commerce, Marketplaces & Omnichannel. REST APIs, TypeScript SDKs, and production-ready Next.js storefront. Self-host it. Own your data. No vendor lock-in. Zero platform fees.

Check for linked_resource.nil?

Matthew Kennedy36bd7394ce08
diff --git a/core/app/models/spree/menu_item.rb b/core/app/models/spree/menu_item.rb
index 1cfd6cb123..f1d60ac138 100644
--- a/core/app/models/spree/menu_item.rb
+++ b/core/app/models/spree/menu_item.rb
@@ -28,7 +28,7 @@ module Spree
def destination
if DYNAMIC_RESOURCE_TYPE.include? linked_resource_type
- return if linked_resource_id.nil?
+ return if linked_resource.nil?
case linked_resource_type
when 'Spree::Taxon'