Skip to content

Commit

Permalink
Fix missing project_id of dataset/table
Browse files Browse the repository at this point in the history
  • Loading branch information
hakobera committed Jun 5, 2016
1 parent 0c8b691 commit e815848
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/tumugi/plugin/target/bigquery_dataset.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ def initialize(project_id: nil, dataset_id:, client: nil)
@project_id = project_id || cfg.project_id
@dataset_id = dataset_id
@client = client || Tumugi::Plugin::Bigquery::Client.new(cfg.to_h.merge(project_id: @project_id))
@dataset = Tumugi::Plugin::Bigquery::Dataset.new(project_id: @project_id, dataset_id: @dataset_id)
@dataset = Tumugi::Plugin::Bigquery::Dataset.new(project_id: @client.project_id, dataset_id: @dataset_id)
end

def exist?
Expand Down
2 changes: 1 addition & 1 deletion lib/tumugi/plugin/target/bigquery_table.rb
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ def initialize(project_id: nil, dataset_id:, table_id:, client: nil)
@dataset_id = dataset_id
@table_id = table_id
@client = client || Tumugi::Plugin::Bigquery::Client.new(cfg.to_h.merge(project_id: @project_id))
@table = Tumugi::Plugin::Bigquery::Table.new(project_id: @project_id, dataset_id: @dataset_id, table_id: @table_id)
@table = Tumugi::Plugin::Bigquery::Table.new(project_id: @client.project_id, dataset_id: @dataset_id, table_id: @table_id)
end

def exist?
Expand Down

0 comments on commit e815848

Please sign in to comment.