fix: format all Go files with gofmt
- Fix alignment in struct fields (sessionProfileResponse, textureInfo, Handler) - Align struct field values in internal/templates/templates.go, internal/api/api.go
This commit is contained in:
@@ -20,18 +20,18 @@ import (
|
||||
|
||||
// mimeByExtension maps common file extensions to MIME types for CAS serving.
|
||||
var mimeByExtension = map[string]string{
|
||||
".jar": "application/java-archive",
|
||||
".json": "application/json",
|
||||
".png": "image/png",
|
||||
".zip": "application/zip",
|
||||
".toml": "application/toml",
|
||||
".cfg": "text/plain",
|
||||
".conf": "text/plain",
|
||||
".txt": "text/plain",
|
||||
".log": "text/plain",
|
||||
".xml": "application/xml",
|
||||
".yml": "application/x-yaml",
|
||||
".yaml": "application/x-yaml",
|
||||
".jar": "application/java-archive",
|
||||
".json": "application/json",
|
||||
".png": "image/png",
|
||||
".zip": "application/zip",
|
||||
".toml": "application/toml",
|
||||
".cfg": "text/plain",
|
||||
".conf": "text/plain",
|
||||
".txt": "text/plain",
|
||||
".log": "text/plain",
|
||||
".xml": "application/xml",
|
||||
".yml": "application/x-yaml",
|
||||
".yaml": "application/x-yaml",
|
||||
".properties": "text/plain",
|
||||
}
|
||||
|
||||
|
||||
@@ -14,10 +14,10 @@ func TestIsValidHash(t *testing.T) {
|
||||
{"a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2", true},
|
||||
{"0000000000000000000000000000000000000000", true},
|
||||
{"ffffffffffffffffffffffffffffffffffffffff", true},
|
||||
{"A1B2C3D4E5F6A1B2C3D4E5F6A1B2C3D4E5F6A1B2", false}, // uppercase
|
||||
{"g1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2", false}, // non-hex
|
||||
{"a1b2c3d4e5f6", false}, // too short
|
||||
{"", false}, // empty
|
||||
{"A1B2C3D4E5F6A1B2C3D4E5F6A1B2C3D4E5F6A1B2", false}, // uppercase
|
||||
{"g1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2", false}, // non-hex
|
||||
{"a1b2c3d4e5f6", false}, // too short
|
||||
{"", false}, // empty
|
||||
{"a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3", false}, // too long (41)
|
||||
}
|
||||
for _, tt := range tests {
|
||||
|
||||
Reference in New Issue
Block a user