mirror of
				https://github.com/go-gitea/gitea
				synced 2025-11-04 05:18:25 +00:00 
			
		
		
		
	Backport #27584 by @wxiaoguang Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
This commit is contained in:
		@@ -107,12 +107,11 @@ func ListTasks() TaskTable {
 | 
				
			|||||||
			prev = e.PreviousRun()
 | 
								prev = e.PreviousRun()
 | 
				
			||||||
		}
 | 
							}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							task.lock.Lock()
 | 
				
			||||||
		// If the manual run is after the cron run, use that instead.
 | 
							// If the manual run is after the cron run, use that instead.
 | 
				
			||||||
		if prev.Before(task.LastRun) {
 | 
							if prev.Before(task.LastRun) {
 | 
				
			||||||
			prev = task.LastRun
 | 
								prev = task.LastRun
 | 
				
			||||||
		}
 | 
							}
 | 
				
			||||||
 | 
					 | 
				
			||||||
		task.lock.Lock()
 | 
					 | 
				
			||||||
		tTable = append(tTable, &TaskTableRow{
 | 
							tTable = append(tTable, &TaskTableRow{
 | 
				
			||||||
			Name:        task.Name,
 | 
								Name:        task.Name,
 | 
				
			||||||
			Spec:        spec,
 | 
								Spec:        spec,
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user