Hi Shopify App Store developer,
can help to check what why facing error during update value into key “layout/theme.liquid” ?
error code return :
Shopify Index Page Error : {“errors”:“Not Found”,“error_reference”:“If you report this error, please include this id: 21770abd-c6a1-442e-833a-f32e5536ddcb-1715762926.”}
here is code request :
theme = ShopifyAPI::Theme.all&.find { |t| t.role == “main” }
if theme&.id.present?
asset = ShopifyAPI::Asset.all(theme_id: theme.id, asset: {“key” => “layout/theme.liquid”})&.first
if asset&.value.present?
test_session = ShopifyAPI::Context.active_session
update_asset = ShopifyAPI::Asset.new(session: test_session)
update_asset.theme_id = theme.id
update_asset.key = “layout/theme.liquid”
update_asset.value = asset.value.sub(“”, "