aboutsummaryrefslogtreecommitdiffstats
path: root/lib/active_text/attachment.rb
diff options
context:
space:
mode:
authorSam Stephenson <sam@37signals.com>2018-02-13 15:00:14 -0600
committerSam Stephenson <sam@37signals.com>2018-02-13 15:00:14 -0600
commitd1f50a4cbe54d15a07608b20ed2fc05e8960bc1d (patch)
tree118aaa4741567dfbcdea8afba33e194d43fd3d33 /lib/active_text/attachment.rb
parent2ae84d647feac338082175f581bd1ca0c33d003a (diff)
downloadrails-d1f50a4cbe54d15a07608b20ed2fc05e8960bc1d.tar.gz
rails-d1f50a4cbe54d15a07608b20ed2fc05e8960bc1d.tar.bz2
rails-d1f50a4cbe54d15a07608b20ed2fc05e8960bc1d.zip
Preserve the outer attachment element and fix editing
Diffstat (limited to 'lib/active_text/attachment.rb')
-rw-r--r--lib/active_text/attachment.rb6
1 files changed, 1 insertions, 5 deletions
diff --git a/lib/active_text/attachment.rb b/lib/active_text/attachment.rb
index e349c721b2..870390f63e 100644
--- a/lib/active_text/attachment.rb
+++ b/lib/active_text/attachment.rb
@@ -74,11 +74,7 @@ module ActiveText
end
def to_html
- if attachable.respond_to?(:to_partial_path)
- ApplicationController.render(self)
- else
- HtmlConversion.node_to_html(node)
- end
+ HtmlConversion.node_to_html(node)
end
def to_s