commit b06b25c58a0ebeaf58a44f28f1422b842144e507 from: Oliver Lowe date: Wed Jan 12 10:51:11 2022 UTC Remove unused attrs() method It was required to satisfty the object interface but the interface changed because it wasn't used anywhere. commit - 6c70362050af3bf13a06cde4ed47aa49064b1813 commit + b06b25c58a0ebeaf58a44f28f1422b842144e507 blob - c91758f751aced6fa19666b0f27ba3d014a2446a blob + 2638ec294b6d52c607f76c143cc758f79369aa0e --- host.go +++ host.go @@ -41,12 +41,6 @@ func (h Host) path() string { return "/objects/hosts/" + h.Name } -func (h Host) attrs() map[string]interface{} { - m := make(map[string]interface{}) - m["display_name"] = h.DisplayName - return m -} - func (h Host) MarshalJSON() ([]byte, error) { type Attrs struct { Address string `json:"address"` blob - 57ff914a3e5b3f142c17ae0e797b260301b9233d blob + 466257ef50678e8aa174715dd15478a37feebd86 --- service.go +++ service.go @@ -10,12 +10,6 @@ func (s Service) path() string { return "/objects/services/" + s.Name } -func (s Service) attrs() map[string]interface{} { - m := make(map[string]interface{}) - m["display_name"] = s.DisplayName - return m -} - // Service represents a Service object. type Service struct { Name string `json:"__name"` blob - b9c85caf88e41b5f1c13adf09e932558615f949f blob + 45230aa14d4a1f50c23ce0ae9f02ee702058b170 --- user.go +++ user.go @@ -37,10 +37,3 @@ func (u User) name() string { func (u User) path() string { return "/objects/users/" + u.Name } - -func (u User) attrs() map[string]interface{} { - m := make(map[string]interface{}) - m["groups"] = u.Groups - m["email"] = u.Email - return m -}