Explorar o código

fix image controller to return image url correctly

Kylie Jo Swistak %!s(int64=6) %!d(string=hai) anos
pai
achega
e76e172534
Modificáronse 1 ficheiros con 5 adicións e 1 borrados
  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