lalala 4.1.0.dev.386 → 4.1.0.dev.387
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e37a0475df835fc6ed0e38b1d7018ff2e452a2a0
|
4
|
+
data.tar.gz: 4b094e5fbb5023efb596a11d20b5ca0294ff70bd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d6db6f49bda2370c06827328c846d9db2df395a5880457f7b290d3f946ef88c66c47197321eaea91144d9a10a9811a03f0053d3547f1d0cb6bc9cfcf84c4230a
|
7
|
+
data.tar.gz: daae32cd944e668193fe7544643d9a88a89174a755e4b1b583b778393d0171ee21e48458b78432e4549ee0fbf06da9268529f47d95f8d20fff64df0723023173
|
data/lib/lalala/engine.rb
CHANGED
@@ -12,6 +12,7 @@ module Lalala
|
|
12
12
|
config.lalala = ActiveSupport::OrderedOptions.new
|
13
13
|
config.lalala.i18n = ActiveSupport::OrderedOptions.new
|
14
14
|
config.lalala.i18n.adapter = nil
|
15
|
+
config.lalala.i18n.allow_accept_language = true
|
15
16
|
|
16
17
|
initializer "lalala.migrations" do |app|
|
17
18
|
app.class.configure do
|
@@ -63,13 +63,15 @@ private
|
|
63
63
|
return action(true)
|
64
64
|
end
|
65
65
|
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
66
|
+
if @adapter.allow_accept_language
|
67
|
+
Rails.logger.debug "[I18n]: try Accept-Language..."
|
68
|
+
if m = accept_language_is_available?
|
69
|
+
@env['rack.locale'] = m[0]
|
70
|
+
@env['SCRIPT_NAME'] = m[1]
|
71
|
+
@env['lalala.cannonical_url'] = m[2]
|
72
|
+
@env['lalala.locale.source'] = 'header'
|
73
|
+
return action(false)
|
74
|
+
end
|
73
75
|
end
|
74
76
|
|
75
77
|
@env['rack.locale'] = default_locale_for_hostname.to_sym
|
data/lib/lalala/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: lalala
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.1.0.dev.
|
4
|
+
version: 4.1.0.dev.387
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Simon Menke
|
@@ -13,7 +13,7 @@ authors:
|
|
13
13
|
autorequire:
|
14
14
|
bindir: bin
|
15
15
|
cert_chain: []
|
16
|
-
date: 2015-
|
16
|
+
date: 2015-02-10 00:00:00.000000000 Z
|
17
17
|
dependencies:
|
18
18
|
- !ruby/object:Gem::Dependency
|
19
19
|
name: activeadmin
|