aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRobin Houston <robin.houston@gmail.com>2012-07-04 11:43:35 +0100
committerRobin Houston <robin.houston@gmail.com>2012-07-04 11:43:35 +0100
commit886a8baef232cce37c829137a8b6a625d16b0504 (patch)
tree43a6441c36a7ee08fc9efc3e90c05e50e5ca2b30
parentf03d71e493085c49e9c0a79c8608becd0b526c00 (diff)
Use fully-qualified URLs in feed
The <link> tags in the feed <entry>s ought to be fully-qualified URLs.
-rwxr-xr-xapp/helpers/link_to_helper.rb7
1 files changed, 6 insertions, 1 deletions
diff --git a/app/helpers/link_to_helper.rb b/app/helpers/link_to_helper.rb
index 5bba5d312..efa20b723 100755
--- a/app/helpers/link_to_helper.rb
+++ b/app/helpers/link_to_helper.rb
@@ -16,7 +16,12 @@ module LinkToHelper
params = {:url_title => info_request.url_title, :only_path => true}
return show_request_url(params.merge(extra_params))
end
- alias :info_request_url :request_url
+
+ def info_request_url(info_request)
+ # This method is called implicitly by the builder view views/api/new_requests.atom.builder
+ # to construct the URLs for the feed entries. Therefore we return fully-qualified URLs here.
+ return main_url(request_url(info_request))
+ end
def request_link(info_request, cls=nil )
link_to h(info_request.title), request_url(info_request), :class => cls