Use a method to change the CreatePage function.
diff --git a/rackspace/identity/v2/extensions/delegate.go b/rackspace/identity/v2/extensions/delegate.go
index ffbcf92..3500cfd 100644
--- a/rackspace/identity/v2/extensions/delegate.go
+++ b/rackspace/identity/v2/extensions/delegate.go
@@ -43,11 +43,9 @@
// List returns a Pager which allows you to iterate over the full collection of extensions.
// It does not accept query parameters.
func List(c *gophercloud.ServiceClient) pagination.Pager {
- pager := os.List(c)
- pager.CreatePage = func(r pagination.LastHTTPResponse) pagination.Page {
+ return os.List(c).WithPageCreator(func(r pagination.LastHTTPResponse) pagination.Page {
return ExtensionPage{
ExtensionPage: common.ExtensionPage{SinglePageBase: pagination.SinglePageBase(r)},
}
- }
- return pager
+ })
}