Parcourir la source

fix image controller to return image url correctly

Kylie Jo Swistak il y a 6 ans
Parent
commit
e76e172534
1 fichiers modifiés avec 5 ajouts et 1 suppressions
  1. 5 1
      app/controllers/image_controller.rb

+ 5 - 1
app/controllers/image_controller.rb

@@ -6,6 +6,10 @@ class ImageController
       end
     end
 
-    image
+    if image
+      image.url
+    else
+      image_url[1]
+    end
   end
 end