Extract out user functionality into its own namespace
diff --git a/openstack/db/v1/instances/results.go b/openstack/db/v1/instances/results.go
index f211868..fa2d64e 100644
--- a/openstack/db/v1/instances/results.go
+++ b/openstack/db/v1/instances/results.go
@@ -3,6 +3,7 @@
import (
"github.com/mitchellh/mapstructure"
"github.com/rackspace/gophercloud"
+ "github.com/rackspace/gophercloud/openstack/db/v1/users"
"github.com/rackspace/gophercloud/pagination"
)
@@ -56,15 +57,6 @@
Volume Volume
}
-// User represents a database user
-type User struct {
- // The user name
- Name string
-
- // The user password
- Password string
-}
-
type commonResult struct {
gophercloud.Result
}
@@ -154,7 +146,7 @@
}
var response struct {
- User User `mapstructure:"user"`
+ User users.User `mapstructure:"user"`
}
err := mapstructure.Decode(r.Body, &response)