adlio / trello

Trello API wrapper for Go
MIT License
219 stars 71 forks source link

Extracted field structs to named structs for ease of use in empty struct checks #91

Closed justinfarrelldev closed 2 years ago

justinfarrelldev commented 2 years ago

I extracted the structs that were inline in board.go and card.go into their own exported (named) structs. This should make it easier to check if they are empty by allowing checks such as this:

// Where board is an initialized Board
if board.Prefs == BoardPrefs{} {
// This is empty
} else {
// There are prefs here
}