diff --git a/app/controllers/concerns/decidim/simple_proposal/proposals_controller_override.rb b/app/controllers/concerns/decidim/simple_proposal/proposals_controller_override.rb index ae478df4..4915e9b2 100644 --- a/app/controllers/concerns/decidim/simple_proposal/proposals_controller_override.rb +++ b/app/controllers/concerns/decidim/simple_proposal/proposals_controller_override.rb @@ -24,7 +24,9 @@ def index .not_hidden @proposals = @base_query.includes(:component, :coauthorships) - @all_geocoded_proposals = @base_query.geocoded.where.not(latitude: Float::NAN, longitude: Float::NAN) + @all_geocoded_proposals = @base_query.geocoded + .where.not(latitude: Float::NAN) + .where.not(longitude: Float::NAN) @voted_proposals = if current_user ::Decidim::Proposals::ProposalVote.where( diff --git a/spec/controllers/decidim/proposals/proposals_controller_spec.rb b/spec/controllers/decidim/proposals/proposals_controller_spec.rb index f8bf57a7..faad774e 100644 --- a/spec/controllers/decidim/proposals/proposals_controller_spec.rb +++ b/spec/controllers/decidim/proposals/proposals_controller_spec.rb @@ -267,7 +267,7 @@ module Proposals it "is not able to withdraw the proposal" do put :withdraw, params: params.merge(id: proposal.id) - expect(flash[:alert]).to eq("This proposal can not be withdrawn because it already has supports.") + expect(flash[:alert]).to eq("This idea can not be withdrawn because it already has supports.") expect(response).to have_http_status(:found) proposal.reload expect(proposal.withdrawn?).to be false