From 313e07876d5135d5209bf8515e4fdda1320e24f1 Mon Sep 17 00:00:00 2001 From: Anna Lushnikova Date: Thu, 31 Oct 2024 08:42:14 -0400 Subject: [PATCH] Update droplets.go Co-authored-by: Andrew Starr-Bochicchio --- droplets.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/droplets.go b/droplets.go index b3829a1..dabaec5 100644 --- a/droplets.go +++ b/droplets.go @@ -682,8 +682,12 @@ func (s *DropletsServiceOp) GetBackupPolicy(ctx context.Context, dropletID int) } // List all droplet backup policies. -func (s *DropletsServiceOp) ListBackupPolicies(ctx context.Context) ([]*DropletBackupPolicy, *Response, error) { +func (s *DropletsServiceOp) ListBackupPolicies(ctx context.Context, opt *ListOptions) (map[int]*DropletBackupPolicy, *Response, error) { path := fmt.Sprintf("%s/backups/policies", dropletBasePath) + path, err := addOptions(path, opt) + if err != nil { + return nil, nil, err + } req, err := s.client.NewRequest(ctx, http.MethodGet, path, nil) if err != nil { return nil, nil, err