mirror of
				https://github.com/go-gitea/gitea.git
				synced 2025-10-31 10:56:10 +01:00 
			
		
		
		
	Reduce some allocations in type conversion (#26772)
This commit is contained in:
		| @@ -755,11 +755,11 @@ func GetSquashMergeCommitMessages(ctx context.Context, pr *issues_model.PullRequ | ||||
| 	} | ||||
|  | ||||
| 	for _, author := range authors { | ||||
| 		if _, err := stringBuilder.Write([]byte("Co-authored-by: ")); err != nil { | ||||
| 		if _, err := stringBuilder.WriteString("Co-authored-by: "); err != nil { | ||||
| 			log.Error("Unable to write to string builder Error: %v", err) | ||||
| 			return "" | ||||
| 		} | ||||
| 		if _, err := stringBuilder.Write([]byte(author)); err != nil { | ||||
| 		if _, err := stringBuilder.WriteString(author); err != nil { | ||||
| 			log.Error("Unable to write to string builder Error: %v", err) | ||||
| 			return "" | ||||
| 		} | ||||
|   | ||||
		Reference in New Issue
	
	Block a user