google-cloud-logging 1.3.0 → 1.3.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/google/cloud/logging/rails.rb +8 -2
- data/lib/google/cloud/logging/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7508ce0ad219483a9a7080088c34e6e004b1e3a1d3ccb8a94fe7266a4bc73aa1
|
4
|
+
data.tar.gz: 5b78941210458eca6f4e7a8135022066f6c033bb535195b78355a40f90b881c9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d8bb6191a3526f090d8d6ad421c0f5be39f32abade8fb96c96274abbf523b55ece4aa827a8792b77acc6e81183fe4735838410829a4c4aae547b66068eb13b6c
|
7
|
+
data.tar.gz: e5918c45cbb8e002fa2211f2c4230b7cd8bae6adfb7d2b62aa193b837b11d5a424bde85af22c3b5e20659c9e596fc1f3e51189148677fc9890f277d5857e25f4
|
@@ -138,11 +138,17 @@ module Google
|
|
138
138
|
|
139
139
|
##
|
140
140
|
# @private Verify credentials
|
141
|
-
def self.valid_credentials? project_id,
|
141
|
+
def self.valid_credentials? project_id, credentials
|
142
142
|
# Try authenticate authorize client API. Return false if unable to
|
143
143
|
# authorize.
|
144
144
|
begin
|
145
|
-
|
145
|
+
# if credentials is nil, get default
|
146
|
+
credentials ||= Logging::Credentials.default
|
147
|
+
# only create a new Credentials object if the val isn't one already
|
148
|
+
unless credentials.is_a? Google::Auth::Credentials
|
149
|
+
# if credentials is not a Credentials object, create one
|
150
|
+
Logging::Credentials.new credentials
|
151
|
+
end
|
146
152
|
rescue Exception => e
|
147
153
|
STDOUT.puts "Note: Google::Cloud::Logging is disabled because " \
|
148
154
|
"it failed to authorize with the service. (#{e.message}) " \
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: google-cloud-logging
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.3.
|
4
|
+
version: 1.3.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mike Moore
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2017-11-
|
12
|
+
date: 2017-11-16 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: google-cloud-core
|