aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Landauer <matthew@openaustralia.org>2012-09-25 09:15:47 +1000
committerMatthew Landauer <matthew@openaustralia.org>2012-09-25 09:15:47 +1000
commit6ee1e8d0a4a8cfe02797c1a853bf27af2610ad27 (patch)
tree8e46da78fec42c9df59c1fe4923895d74229a5bc
parent5e3e0ae67f6afa0fa648b7015e89871bee22b23f (diff)
Inline ConfigHelper force_registration_on_new_request
-rw-r--r--app/controllers/request_controller.rb2
-rw-r--r--app/helpers/config_helper.rb4
-rw-r--r--app/views/general/_stylesheet_includes.rhtml2
-rw-r--r--app/views/layouts/default.rhtml2
4 files changed, 3 insertions, 7 deletions
diff --git a/app/controllers/request_controller.rb b/app/controllers/request_controller.rb
index 9ad328a0c..07d188079 100644
--- a/app/controllers/request_controller.rb
+++ b/app/controllers/request_controller.rb
@@ -30,7 +30,7 @@ class RequestController < ApplicationController
def select_authority
# Check whether we force the user to sign in right at the start, or we allow her
# to start filling the request anonymously
- if force_registration_on_new_request && !authenticated?(
+ if Configuration::force_registration_on_new_request && !authenticated?(
:web => _("To send your FOI request"),
:email => _("Then you'll be allowed to send FOI requests."),
:email_subject => _("Confirm your email address")
diff --git a/app/helpers/config_helper.rb b/app/helpers/config_helper.rb
index 0f18c0c4b..73e12172f 100644
--- a/app/helpers/config_helper.rb
+++ b/app/helpers/config_helper.rb
@@ -2,8 +2,4 @@ module ConfigHelper
def site_name
Configuration::site_name
end
-
- def force_registration_on_new_request
- Configuration::force_registration_on_new_request
- end
end \ No newline at end of file
diff --git a/app/views/general/_stylesheet_includes.rhtml b/app/views/general/_stylesheet_includes.rhtml
index 2ffa5dadf..7a03680f8 100644
--- a/app/views/general/_stylesheet_includes.rhtml
+++ b/app/views/general/_stylesheet_includes.rhtml
@@ -16,6 +16,6 @@
<![endif]-->
<!-- the following method for customising CSS is deprecated; see `doc/THEMES.md` for detail -->
<%= stylesheet_link_tag 'custom', :title => "Main", :rel => "stylesheet" %>
- <% if force_registration_on_new_request %>
+ <% if Configuration::force_registration_on_new_request %>
<%= stylesheet_link_tag 'jquery.fancybox-1.3.4', :rel => "stylesheet" %>
<% end %>
diff --git a/app/views/layouts/default.rhtml b/app/views/layouts/default.rhtml
index 21479239c..0dd493fd0 100644
--- a/app/views/layouts/default.rhtml
+++ b/app/views/layouts/default.rhtml
@@ -42,7 +42,7 @@
<%= render :partial => 'general/before_head_end' %>
</head>
<body class="<%= 'admin' if is_admin? %> <%= 'front' if params[:action] == 'frontpage' %>">
- <% if force_registration_on_new_request && !@user %>
+ <% if Configuration::force_registration_on_new_request && !@user %>
<%= javascript_include_tag 'jquery.fancybox-1.3.4.pack' %>
<script type="text/javascript">
$(document).ready(function() {