mirror of
https://github.com/letic/terraform-provider-google.git
synced 2024-10-04 17:51:11 +00:00
Merge pull request #1407 from terraform-providers/paddy_sql_err
Check error in SQL user test.
This commit is contained in:
commit
c5580ca12d
@ -91,6 +91,10 @@ func testAccCheckGoogleSqlUserExists(n string) resource.TestCheckFunc {
|
||||
users, err := config.clientSqlAdmin.Users.List(config.Project,
|
||||
instance).Do()
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
for _, user := range users.Items {
|
||||
if user.Name == name && user.Host == host {
|
||||
return nil
|
||||
|
Loading…
Reference in New Issue
Block a user