Separating rebuild result type from other actions
diff --git a/openstack/compute/v2/servers/results.go b/openstack/compute/v2/servers/results.go
index 492c5a8..1402d8a 100644
--- a/openstack/compute/v2/servers/results.go
+++ b/openstack/compute/v2/servers/results.go
@@ -40,10 +40,20 @@
}
// RebuildResult temporarily contains the response from a Rebuild call.
-type ActionResult struct {
+type RebuildResult struct {
serverResult
}
+// ActionResult represents the result of server action operations, like reboot
+type ActionResult struct {
+ gophercloud.CommonResult
+}
+
+// Extract is a function that extracts error information from a result
+func (r ActionResult) Extract() error {
+ return r.Err
+}
+
// Server exposes only the standard OpenStack fields corresponding to a given server on the user's account.
type Server struct {
// ID uniquely identifies this server amongst all other servers, including those not accessible to the current tenant.