Skip to content

Commit

Permalink
fix codeclimate warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
nemca committed Feb 21, 2020
1 parent 1f3e4d6 commit cf01560
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions apis/cache/flush.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ import (
"github.com/mittwald/go-powerdns/pdnshttp"
)

func (c *client) Flush(ctx context.Context, serverID string, name string) (*CacheFlushResult, error) {
cfr := CacheFlushResult{}
func (c *client) Flush(ctx context.Context, serverID string, name string) (*FlushResult, error) {
cfr := FlushResult{}
path := fmt.Sprintf("/api/v1/servers/%s/cache/flush", url.PathEscape(serverID))

err := c.httpClient.Put(ctx, path, &cfr, pdnshttp.WithQueryValue("domain", name))
Expand Down
4 changes: 2 additions & 2 deletions apis/cache/types.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package cache

// CacheFlushResult represent the result of a cache-flush.
type CacheFlushResult struct {
// FlushResult represent the result of a cache-flush.
type FlushResult struct {
Count int `json:"count"`
Result string `json:"result"`
}

0 comments on commit cf01560

Please sign in to comment.