muck-engine 0.1.20 → 0.1.21
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/lib/action_controller/muck_application.rb +14 -3
- data/locales/en.yml +2 -0
- data/muck-engine.gemspec +1 -1
- metadata +1 -1
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.1.
|
1
|
+
0.1.21
|
@@ -64,7 +64,18 @@ module ActionController
|
|
64
64
|
nil
|
65
65
|
end
|
66
66
|
end
|
67
|
-
|
67
|
+
|
68
|
+
# **********************************************
|
69
|
+
# SSL method
|
70
|
+
# only require ssl if we are in production
|
71
|
+
def ssl_required?
|
72
|
+
return false unless GlobalConfig.enable_ssl
|
73
|
+
return ENV['SSL'] == 'on' ? true : false if defined? ENV['SSL']
|
74
|
+
return false if local_request?
|
75
|
+
return false if RAILS_ENV == 'test'
|
76
|
+
((self.class.read_inheritable_attribute(:ssl_required_actions) || []).include?(action_name.to_sym)) && (RAILS_ENV == 'production' || RAILS_ENV == 'staging')
|
77
|
+
end
|
78
|
+
|
68
79
|
# **********************************************
|
69
80
|
# Paging methods
|
70
81
|
def setup_paging
|
@@ -76,8 +87,8 @@ module ActionController
|
|
76
87
|
def set_will_paginate_string
|
77
88
|
# Because I18n.locale are dynamically determined in ApplicationController,
|
78
89
|
# it should not put in config/initializers/will_paginate.rb
|
79
|
-
WillPaginate::ViewHelpers.pagination_options[:previous_label] = t('
|
80
|
-
WillPaginate::ViewHelpers.pagination_options[:next_label] = t('
|
90
|
+
WillPaginate::ViewHelpers.pagination_options[:previous_label] = t('muck.general.previous')
|
91
|
+
WillPaginate::ViewHelpers.pagination_options[:next_label] = t('muck.general.next')
|
81
92
|
end
|
82
93
|
|
83
94
|
# **********************************************
|
data/locales/en.yml
CHANGED
data/muck-engine.gemspec
CHANGED