getaround_utils 0.2.6 → 0.2.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/getaround_utils/railties/ougai.rb +0 -12
- data/lib/getaround_utils/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b223cad8498dfd12507f6ab773df8a1faf022100f7d853ca5460f4b6777c7182
|
4
|
+
data.tar.gz: fee4b3c9d00bae73b4e6dcb9e03bc41873d322dbade354526e66eb3f86442f14
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 48b823c75460cacf812d6b08adc733821a8cbe8e488441f5ee53ecc3681467d50589195cf8f0781e8c3dcac4a37f6decd56cbb981d6c886f18558e69e72075ad
|
7
|
+
data.tar.gz: ddcc92a0093cb1a6dd63b5510a3c5db012ce0099e43262a8fc5f475bbc722795f42c0e1c411624b5fd5dd1a240434f7b15bed65c47c390345a839fbe487e40fe
|
data/Gemfile.lock
CHANGED
@@ -40,11 +40,8 @@ class OugaiRequestStoreMiddleware
|
|
40
40
|
end
|
41
41
|
|
42
42
|
class GetaroundUtils::Railties::Ougai < Rails::Railtie
|
43
|
-
log_level = ENV.fetch('LOG_LEVEL', :info).to_sym
|
44
|
-
|
45
43
|
config.ougai_logger = OugaiRailsLogger.new(STDOUT)
|
46
44
|
config.ougai_logger.after_initialize if Rails::VERSION::MAJOR < 6
|
47
|
-
config.ougai_logger.level = log_level
|
48
45
|
config.ougai_logger.formatter = GetaroundUtils::Ougai::DeepKeyValueFormatter.new
|
49
46
|
config.ougai_logger.before_log = lambda do |data|
|
50
47
|
request_store = RequestStore.store[:ougai] || {}
|
@@ -55,15 +52,6 @@ class GetaroundUtils::Railties::Ougai < Rails::Railtie
|
|
55
52
|
end
|
56
53
|
|
57
54
|
initializer :getaround_utils_ougai, before: :initialize_logger do |app|
|
58
|
-
LOG_LEVELS = {
|
59
|
-
Logger::DEBUG => :debug,
|
60
|
-
Logger::INFO => :info,
|
61
|
-
Logger::WARN => :warn,
|
62
|
-
Logger::ERROR => :error,
|
63
|
-
Logger::FATAL => :fatal,
|
64
|
-
}.freeze
|
65
|
-
|
66
|
-
app.config.log_level = LOG_LEVELS[config.ougai_logger.level] || :info
|
67
55
|
app.config.logger = config.ougai_logger
|
68
56
|
end
|
69
57
|
|