diff options
| author | Jeff Carr <[email protected]> | 2024-10-22 02:51:45 -0500 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2024-10-22 02:51:45 -0500 |
| commit | bcc97a550a70305f9182b452ef650789c2fa2b45 (patch) | |
| tree | a8d4460d4f94fcb5615719b3b4373c4f93d17e77 /sampleData.go | |
| parent | ec178de1d7b9cd94bdd6ffd6a64b914bae15a549 (diff) | |
is this how to support multiple droplets?
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'sampleData.go')
| -rw-r--r-- | sampleData.go | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sampleData.go b/sampleData.go index b75970b..c910200 100644 --- a/sampleData.go +++ b/sampleData.go @@ -18,9 +18,9 @@ func CreateSampleDroplet() *Droplet { return e } -func CreateSampleDroplets(total int) []Droplet { - - var all []Droplet +func CreateSampleCluster(total int) *Cluster { + var c *Cluster + c = new(Cluster) for i := 0; i < total; i++ { d := CreateSampleDroplet() @@ -28,8 +28,8 @@ func CreateSampleDroplets(total int) []Droplet { // e.Id += 1000 + int32(i) d.Comment = "Sample Droplet " + string(i) - all = append(all, *d) + c.Droplets = append(c.Droplets, d) } - return all + return c } |
