mirror of
https://github.com/go-gitea/gitea
synced 2024-12-21 18:17:57 +01:00
remove some unused changes
This commit is contained in:
parent
130f2a2222
commit
4341ef0fc7
@ -71,7 +71,6 @@ type FindRunOptions struct {
|
|||||||
TriggerEvent webhook_module.HookEventType
|
TriggerEvent webhook_module.HookEventType
|
||||||
Approved bool // not util.OptionalBool, it works only when it's true
|
Approved bool // not util.OptionalBool, it works only when it's true
|
||||||
Status []Status
|
Status []Status
|
||||||
SortType string
|
|
||||||
ConcurrencyGroup string
|
ConcurrencyGroup string
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -108,14 +107,7 @@ func (opts FindRunOptions) ToConds() builder.Cond {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (opts FindRunOptions) ToOrders() string {
|
func (opts FindRunOptions) ToOrders() string {
|
||||||
switch opts.SortType {
|
return "`id` DESC"
|
||||||
case "oldest":
|
|
||||||
return "created ASC"
|
|
||||||
case "newest":
|
|
||||||
return "created DESC"
|
|
||||||
default:
|
|
||||||
return "`id` DESC"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type StatusInfo struct {
|
type StatusInfo struct {
|
||||||
|
@ -92,18 +92,3 @@ func findTaskNeeds(ctx context.Context, task *actions_model.ActionTask) (map[str
|
|||||||
|
|
||||||
return ret, nil
|
return ret, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// mergeTwoOutputs merges two outputs from two different ActionRunJobs
|
|
||||||
// Values with the same output name may be overridden. The user should ensure the output names are unique.
|
|
||||||
// See https://docs.github.com/en/actions/writing-workflows/workflow-syntax-for-github-actions#using-job-outputs-in-a-matrix-job
|
|
||||||
func mergeTwoOutputs(o1, o2 map[string]string) map[string]string {
|
|
||||||
ret := make(map[string]string, len(o1))
|
|
||||||
for k1, v1 := range o1 {
|
|
||||||
if len(v1) > 0 {
|
|
||||||
ret[k1] = v1
|
|
||||||
} else {
|
|
||||||
ret[k1] = o2[k1]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return ret
|
|
||||||
}
|
|
||||||
|
Loading…
Reference in New Issue
Block a user