mirror of
https://github.com/go-gitea/gitea
synced 2025-07-15 15:07:20 +00:00
Adjust object format interface (#28469)
- Remove `ObjectFormatID` - Remove function `ObjectFormatFromID`. - Use `Sha1ObjectFormat` directly but not a pointer because it's an empty struct. - Store `ObjectFormatName` in `repository` struct
This commit is contained in:
@ -131,12 +131,12 @@ func TestGetCommitFilesChanged(t *testing.T) {
|
||||
files []string
|
||||
}{
|
||||
{
|
||||
repo.objectFormat.Empty().String(),
|
||||
repo.objectFormat.EmptyObjectID().String(),
|
||||
"95bb4d39648ee7e325106df01a621c530863a653",
|
||||
[]string{"file1.txt"},
|
||||
},
|
||||
{
|
||||
repo.objectFormat.Empty().String(),
|
||||
repo.objectFormat.EmptyObjectID().String(),
|
||||
"8d92fc957a4d7cfd98bc375f0b7bb189a0d6c9f2",
|
||||
[]string{"file2.txt"},
|
||||
},
|
||||
|
Reference in New Issue
Block a user