mirror of
				https://gitee.com/gitea/gitea
				synced 2025-11-04 16:40:24 +08:00 
			
		
		
		
	Fixed linting errors for variable definitions
This commit is contained in:
		@@ -68,7 +68,7 @@ func (repo *Repository) AddCollaborator(u *User) error {
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
func (repo *Repository) getCollaborations(e Engine) ([]*Collaboration, error) {
 | 
					func (repo *Repository) getCollaborations(e Engine) ([]*Collaboration, error) {
 | 
				
			||||||
	collaborations := make([]*Collaboration, 0)
 | 
						var collaborations []*Collaboration
 | 
				
			||||||
	return collaborations, e.Find(&collaborations, &Collaboration{RepoID: repo.ID})
 | 
						return collaborations, e.Find(&collaborations, &Collaboration{RepoID: repo.ID})
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -65,7 +65,7 @@ func CommitToPushCommit(commit *git.Commit) *PushCommit {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
// ListToPushCommits transforms a list.List to PushCommits type.
 | 
					// ListToPushCommits transforms a list.List to PushCommits type.
 | 
				
			||||||
func ListToPushCommits(l *list.List) *PushCommits {
 | 
					func ListToPushCommits(l *list.List) *PushCommits {
 | 
				
			||||||
	commits := make([]*PushCommit, 0)
 | 
						var commits []*PushCommit
 | 
				
			||||||
	var actEmail string
 | 
						var actEmail string
 | 
				
			||||||
	for e := l.Front(); e != nil; e = e.Next() {
 | 
						for e := l.Front(); e != nil; e = e.Next() {
 | 
				
			||||||
		commit := e.Value.(*git.Commit)
 | 
							commit := e.Value.(*git.Commit)
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user