mirror of
https://github.com/basecamp/once-campfire.git
synced 2026-08-09 16:38:45 +09:00
df76a227dc
First open source release of Campfire 🎉
14 lines
306 B
Ruby
14 lines
306 B
Ruby
module BroadcastsHelper
|
|
def broadcast_image_tag(image, options)
|
|
image_tag(broadcast_image_path(image), options)
|
|
end
|
|
|
|
def broadcast_image_path(image)
|
|
if image.is_a?(Symbol) || image.is_a?(String)
|
|
image_path(image)
|
|
else
|
|
polymorphic_url(image, only_path: true)
|
|
end
|
|
end
|
|
end
|