OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub
Ruby agile-developmentangularbcfboardsbug-trackerganttgantt-chartifcissue-trackerjira-alternativekanbanopenprojectproduct-managementproject-managementproject-planningroadmaprubyscrumtimelineworkflows
Explain `#wrapped?` check on `component` instead of `self`
Aaron Contrerase6b1d7d9c853
diff --git a/app/components/concerns/op_turbo/streamable.rb b/app/components/concerns/op_turbo/streamable.rbindex a2911d2ca06..a1439bc257a 100644--- a/app/components/concerns/op_turbo/streamable.rb+++ b/app/components/concerns/op_turbo/streamable.rb@@ -66,6 +66,9 @@ module OpTurbodef insert_as_turbo_stream(component:, view_context:, action: :append)template = component.render_in(view_context)+ # The component being inserted into the target component+ # needs wrapping, not the target since it isn't the one+ # that needs to be rendered to perform this turbo stream action.unless component.wrapped?raise "You need to wrap your component in a `component_wrapper` block in order to use the turbo-stream methods"end