Skip to content

Commit

Permalink
added back depracted functions
Browse files Browse the repository at this point in the history
Signed-off-by: Amir Malka <[email protected]>
Signed-off-by: David Wertenteil <[email protected]>
  • Loading branch information
amirmalka authored and David Wertenteil committed Feb 5, 2023
1 parent ebb1a5d commit 753fd76
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
5 changes: 5 additions & 0 deletions reporthandling/results/v1/reportsummary/posturecounters.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,11 @@ func (pcounter *PostureCounters) Failed() int {
return pcounter.FailedCounter
}

// deprecated
func (pcounter *PostureCounters) Excluded() int {
return pcounter.ExcludedCounter
}

func (pcounter *PostureCounters) All() int {
return pcounter.Passed() + pcounter.Skipped() + pcounter.Failed()
}
Expand Down
6 changes: 6 additions & 0 deletions reporthandling/results/v1/reportsummary/resourcecounters.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ type ICounters interface {
Passed() int
Skipped() int
Failed() int
Excluded() int // deprecated
All() int
}

Expand Down Expand Up @@ -41,6 +42,11 @@ func (resourceCounters *StatusCounters) Failed() int {
return resourceCounters.FailedResources
}

// deprecated
func (resourceCounters *StatusCounters) Excluded() int {
return resourceCounters.ExcludedResources
}

// NumberOfAll get the number of all resources
func (resourceCounters *StatusCounters) All() int {
return resourceCounters.Failed() + resourceCounters.Passed() + resourceCounters.Skipped()
Expand Down

0 comments on commit 753fd76

Please sign in to comment.