mirror of
				https://gitee.com/gitea/gitea
				synced 2025-11-04 08:30:25 +08:00 
			
		
		
		
	fix #1948
This commit is contained in:
		@@ -79,6 +79,12 @@ func ApiRepoAssignment() macaron.Handler {
 | 
			
		||||
// RepoRef handles repository reference name including those contain `/`.
 | 
			
		||||
func RepoRef() macaron.Handler {
 | 
			
		||||
	return func(ctx *Context) {
 | 
			
		||||
		// Empty repository does not have reference information.
 | 
			
		||||
		if ctx.Repo.Repository.IsBare {
 | 
			
		||||
			ctx.Data["CommitsCount"] = 0
 | 
			
		||||
			return
 | 
			
		||||
		}
 | 
			
		||||
 | 
			
		||||
		var (
 | 
			
		||||
			refName string
 | 
			
		||||
			err     error
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user