Skip to content

Commit

Permalink
fixes extraStatements bug for Spanner\Instance::createDatabase (#499)
Browse files Browse the repository at this point in the history
* fixes extraStatements bug for Spanner\Instance::createDatabase

* fixes tests
  • Loading branch information
bshaffer authored and dwsupplee committed May 18, 2017
1 parent 203e5c5 commit c48e546
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 0 additions & 1 deletion src/Spanner/Connection/Grpc.php
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,6 @@ public function createDatabase(array $args)
$res = $this->send([$this->databaseAdminClient, 'createDatabase'], [
$instanceName,
$this->pluck('createStatement', $args),
$this->pluck('extraStatements', $args),
$this->addResourcePrefixHeader($args, $instanceName)
]);

Expand Down
2 changes: 1 addition & 1 deletion tests/unit/Spanner/Connection/GrpcTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ public function methodProvider()
[
'createDatabase',
['instance' => $instanceName, 'createStatement' => $createStmt, 'extraStatements' => []],
[$instanceName, $createStmt, [], ['userHeaders' => ['google-cloud-resource-prefix' => [$instanceName]]]],
[$instanceName, $createStmt, ['extraStatements' => [], 'userHeaders' => ['google-cloud-resource-prefix' => [$instanceName]]]],
$lro,
null
],
Expand Down

0 comments on commit c48e546

Please sign in to comment.