From 4341ef0fc73c4bb92205c9b35d4d96f1f8fe580c Mon Sep 17 00:00:00 2001
From: Zettat123 <zettat123@gmail.com>
Date: Tue, 17 Dec 2024 14:04:10 +0800
Subject: [PATCH] remove some unused changes

---
 models/actions/run_list.go          | 10 +---------
 routers/api/actions/runner/utils.go | 15 ---------------
 2 files changed, 1 insertion(+), 24 deletions(-)

diff --git a/models/actions/run_list.go b/models/actions/run_list.go
index d30d1d46ce3..2339e139147 100644
--- a/models/actions/run_list.go
+++ b/models/actions/run_list.go
@@ -71,7 +71,6 @@ type FindRunOptions struct {
 	TriggerEvent     webhook_module.HookEventType
 	Approved         bool // not util.OptionalBool, it works only when it's true
 	Status           []Status
-	SortType         string
 	ConcurrencyGroup string
 }
 
@@ -108,14 +107,7 @@ func (opts FindRunOptions) ToConds() builder.Cond {
 }
 
 func (opts FindRunOptions) ToOrders() string {
-	switch opts.SortType {
-	case "oldest":
-		return "created ASC"
-	case "newest":
-		return "created DESC"
-	default:
-		return "`id` DESC"
-	}
+	return "`id` DESC"
 }
 
 type StatusInfo struct {
diff --git a/routers/api/actions/runner/utils.go b/routers/api/actions/runner/utils.go
index be46a5acd56..fd937005048 100644
--- a/routers/api/actions/runner/utils.go
+++ b/routers/api/actions/runner/utils.go
@@ -92,18 +92,3 @@ func findTaskNeeds(ctx context.Context, task *actions_model.ActionTask) (map[str
 
 	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
-}