Skip to content

Commit 13c88e5

Browse files
authored
Merge pull request #9 from learningtapestry/fix-googl-api-namespace
Fix Google API namespace
2 parents bec5bfb + b1346fb commit 13c88e5

File tree

2 files changed

+11
-9
lines changed

2 files changed

+11
-9
lines changed

Gemfile.lock

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
PATH
22
remote: .
33
specs:
4-
lt-google-api (0.1.1)
4+
lt-google-api (0.2.1)
55
google-api-client
66
googleauth
77

@@ -14,9 +14,10 @@ GEM
1414
childprocess (4.0.0)
1515
declarative (0.0.20)
1616
declarative-option (0.1.0)
17-
faraday (1.0.1)
17+
faraday (1.2.0)
1818
multipart-post (>= 1.2, < 3)
19-
google-api-client (0.46.1)
19+
ruby2_keywords
20+
google-api-client (0.52.0)
2021
addressable (~> 2.5, >= 2.5.1)
2122
googleauth (~> 0.9)
2223
httpclient (>= 2.8.1, < 3.0)
@@ -43,13 +44,13 @@ GEM
4344
overcommit (0.57.0)
4445
childprocess (>= 0.6.3, < 5)
4546
iniparse (~> 1.4)
46-
parallel (1.19.2)
47+
parallel (1.20.1)
4748
parser (2.7.2.0)
4849
ast (~> 2.4.1)
4950
public_suffix (4.0.6)
5051
rainbow (3.0.0)
51-
rake (13.0.1)
52-
regexp_parser (1.8.2)
52+
rake (13.0.3)
53+
regexp_parser (2.0.1)
5354
representable (3.0.4)
5455
declarative (< 0.1.0)
5556
declarative-option (< 0.2.0)
@@ -65,9 +66,10 @@ GEM
6566
rubocop-ast (>= 0.6.0)
6667
ruby-progressbar (~> 1.7)
6768
unicode-display_width (>= 1.4.0, < 2.0)
68-
rubocop-ast (0.8.0)
69+
rubocop-ast (1.3.0)
6970
parser (>= 2.7.1.5)
7071
ruby-progressbar (1.10.1)
72+
ruby2_keywords (0.0.2)
7173
signet (0.14.0)
7274
addressable (~> 2.3)
7375
faraday (>= 0.17.3, < 2.0)

lib/lt/google/api/drive.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ def copy(file_ids, folder_id)
3737
else
3838
service.copy_file(
3939
id,
40-
Google::Apis::DriveV3::File.new(name: f.name, parents: [folder_id]),
40+
::Google::Apis::DriveV3::File.new(name: f.name, parents: [folder_id]),
4141
supports_all_drives: true
4242
)
4343
end
@@ -62,7 +62,7 @@ def copy_files(folder_id, target_id)
6262
next if current_files.detect { |f| f.name == file.name }
6363

6464
# copy if it's a new file
65-
new_file = Google::Apis::DriveV3::File.new(name: file.name, parents: [target_id])
65+
new_file = ::Google::Apis::DriveV3::File.new(name: file.name, parents: [target_id])
6666
service.copy_file(file.id, new_file, supports_all_drives: true)
6767
end
6868
end

0 commit comments

Comments
 (0)