From d534e71f52c1442c2ec544a8029295ef84393bb3 Mon Sep 17 00:00:00 2001 From: Rafi Jacoby Date: Thu, 30 Jan 2025 13:29:04 -0600 Subject: [PATCH] Be more generic and handle any tag that doesn't accept 'content' correctly. --- .../app/components/solidus_admin/ui/forms/input/component.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/admin/app/components/solidus_admin/ui/forms/input/component.rb b/admin/app/components/solidus_admin/ui/forms/input/component.rb index 472d315ffb6..26cdf05aa18 100644 --- a/admin/app/components/solidus_admin/ui/forms/input/component.rb +++ b/admin/app/components/solidus_admin/ui/forms/input/component.rb @@ -100,14 +100,14 @@ def call **@attributes } - if @tag == :input + if tag.method(@tag).parameters.any? { |type, name| name == :content } tag.public_send( @tag, + content, **options) else tag.public_send( @tag, - content, **options) end end