Quick correction, to render the correct number of organisations. Refs #71

This commit is contained in:
echarp 2016-04-16 23:34:22 +02:00
parent f02c0b10f2
commit 88ec02e006

View File

@ -16,7 +16,7 @@ class MapsController < ApplicationController
def show
kind = Kind.find_by_name params[:id]
orgas = apply_scopes(Orga.moderated.geo).joins(:kind).find_by(kind: kind)
orgas = apply_scopes(Orga.moderated.geo).joins(:kind).where(kind: kind)
respond_to do |format|
format.json { render json: orgas }
end