diff options
author | Robin Houston <robin.houston@gmail.com> | 2012-05-03 18:57:51 +0100 |
---|---|---|
committer | Robin Houston <robin.houston@gmail.com> | 2012-05-03 18:57:51 +0100 |
commit | 20324887036cccc940e1d68fe8c99864b5b634bd (patch) | |
tree | e8968ddf336b65d40d295421d19091f061d940ca /app/controllers/application_controller.rb | |
parent | c86325840e2204daea36e68fac045a215a26eafe (diff) | |
parent | 858898510fe77550ac6550a6b306b5c7a2b93d31 (diff) |
Merge branch 'develop' of github.com:sebbacon/alaveteli into develop
Diffstat (limited to 'app/controllers/application_controller.rb')
-rw-r--r-- | app/controllers/application_controller.rb | 11 |
1 files changed, 1 insertions, 10 deletions
diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index 0ec8e206e..0d0cca3e4 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -1,3 +1,4 @@ +# -*- coding: utf-8 -*- # controllers/application.rb: # Parent class of all controllers in FOI site. Filters added to this controller # apply to all controllers in the application. Likewise, all the methods added @@ -543,16 +544,6 @@ class ApplicationController < ActionController::Base return country end - def quietly_try_to_open(url) - begin - result = open(url).read.strip - rescue OpenURI::HTTPError, SocketError, Errno::ETIMEDOUT, Errno::ECONNREFUSED, Errno::EHOSTUNREACH - logger.warn("Unable to open third-party URL #{url}") - result = "" - end - return result - end - # URL generating functions are needed by all controllers (for redirects), # views (for links) and mailers (for use in emails), so include them into # all of all. |