From 1c385e831a2bfbe621d13ce5c119ea63546dd2d3 Mon Sep 17 00:00:00 2001 From: Saurabh Bhatia Date: Thu, 20 Mar 2014 17:22:39 +0800 Subject: [PATCH] Corrected API url for locations --- app/controllers/api_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/api_controller.rb b/app/controllers/api_controller.rb index 955f2c7..d7ec04a 100644 --- a/app/controllers/api_controller.rb +++ b/app/controllers/api_controller.rb @@ -57,7 +57,7 @@ class ApiController < ApplicationController I18n.locale = :zh_tw name_zh_tw = category.title category_id = category.id.to_s - @data << { name_en: name_en, name_zh_tw: name_zh_tw, category_id: category_id, location_link: "http://#{request.host_with_port}"+"/#{get_locations_api_index_path}"+"?category_id=#{category_id}"} + @data << { name_en: name_en, name_zh_tw: name_zh_tw, category_id: category_id, location_link: "http://#{request.host_with_port}"+"#{get_locations_api_index_path}"+"?category_id=#{category_id}"} end render :json => JSON.pretty_generate(@data)