Skip to content

Commit 14423a7

Browse files
committed
fix(gem): guard Rails-only debug hook in Base component
1 parent 81280b1 commit 14423a7

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

gem/lib/ruby_ui/base.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ def default_attrs
1919
{}
2020
end
2121

22-
if Rails.env.development?
22+
if defined?(Rails) && Rails.env.development?
2323
def before_template
2424
comment { "Before #{self.class.name}" }
2525
end

0 commit comments

Comments
 (0)