Cb-tumblebug: Exported type should have comment or be unexported (golint)

Created on 26 Sep 2021  路  5Comments  路  Source: cloud-barista/cb-tumblebug

What would you like to be enhanced
Exported type should have comment or be unexported (golint) for

cb-tumblebug/src/core/mcir/common.go

  • Line 431: warning: exported type SpiderNameIdSystemId should have comment or be unexported (golint)
  • Line 436: warning: exported type SpiderAllListWrapper should have comment or be unexported (golint)
  • Line 440: warning: exported type SpiderAllList should have comment or be unexported (golint)
  • Line 446: warning: comment on exported type TbInspectResourcesResponse should be of the form "TbInspectResourcesResponse ..." (with optional leading article) (golint)
  • Line 1031: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
  • Line 1236: warning: exported type ReturnValue should have comment or be unexported (golint)
  • Line 1240: warning: exported type NameOnly should have comment or be unexported (golint)
  • Line 1254: warning: if block ends with a return statement, so drop this else and outdent its block (golint)

Why is this needed
To resolve #654 (Update source codes to comply with golint) partially.

Proposed solution

Add comments in cb-tumblebug/src/core/mcir/common.go


    • [x] Line 431: warning: exported type SpiderNameIdSystemId should have comment or be unexported (golint)


    • [x] Line 436: warning: exported type SpiderAllListWrapper should have comment or be unexported (golint)


    • [x] Line 440: warning: exported type SpiderAllList should have comment or be unexported (golint)


    • [x] Line 446: warning: comment on exported type TbInspectResourcesResponse should be of the form "TbInspectResourcesResponse ..." (with optional leading article) (golint)


    • [ ] Line 1236: warning: exported type ReturnValue should have comment or be unexported (golint)


    • [ ] Line 1240: warning: exported type NameOnly should have comment or be unexported (golint)

enhancement

All 5 comments

Tip


    • [x] Line 431: warning: exported type SpiderNameIdSystemId should have comment or be unexported (golint)

// SpiderNameIdSystemId is struct for mapping NameID and System ID from CB-Spider response.


    • [x] Line 436: warning: exported type SpiderAllListWrapper should have comment or be unexported (golint)

// SpiderAllListWrapper is struct for wrapping SpiderAllList struct from CB-Spider response.


    • [x] Line 440: warning: exported type SpiderAllList should have comment or be unexported (golint)

// SpiderAllList is struct for OnlyCSPList, OnlySpiderList MappedList from CB-Spider response.


    • [x] Line 446: warning: comment on exported type TbInspectResourcesResponse should be of the form "TbInspectResourcesResponse ..." (with optional leading article) (golint)

// Response struct for InspectResources
-->
// TbInspectResourcesResponse is struct for response of InspectResources request

    • [ ] Line 1236: warning: exported type ReturnValue should have comment or be unexported (golint)
    • [ ] Line 1240: warning: exported type NameOnly should have comment or be unexported (golint)

鞝滉皜 Task 1氩堨潉 觳橂Μ頃措炒瓴犾姷雼堧嫟!

鞝滉皜 Task 3氩堨潉 觳橂Μ頃措炒瓴犾姷雼堧嫟

鞝滉皜 task 2氩堩晿瓴犾姷雼堧嫟

鞝滉皜 Task 4氩堨潉 觳橂Μ頃措炒瓴犾姷雼堧嫟!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

seokho-son picture seokho-son  路  5Comments

seokho-son picture seokho-son  路  3Comments

seokho-son picture seokho-son  路  3Comments

seokho-son picture seokho-son  路  5Comments

jihoon-seo picture jihoon-seo  路  4Comments