dmitri.shuralyov.com/service/change

Adjust state filter for changes.
dmitshur committed 7 years ago commit 6ec226ef3dbf9214ddd88bd064e93e00998effaa
Showing partial commit. Full Commit
Collapse all
changes.go
@@ -61,19 +61,23 @@ const (
	MergedState State = "merged"
)

// ListOptions are options for list operations.
type ListOptions struct {
	State StateFilter
	Filter StateFilter
}

// StateFilter is a filter by state.
type StateFilter State
type StateFilter string

const (
	// AllStates is a state filter that includes all issues.
	AllStates StateFilter = "all"
	// FilterOpen is a state filter that includes open changes.
	FilterOpen StateFilter = "open"
	// FilterClosedMerged is a state filter that includes closed and merged changes.
	FilterClosedMerged StateFilter = "closed|merged"
	// FilterAll is a state filter that includes all changes.
	FilterAll StateFilter = "all"
)

type GetDiffOptions struct {
	// Commit is the commit ID of the commit to fetch.
	Commit string