feat(backend): update Square integration, validators, and image validation

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
2026-06-18 16:26:47 +01:00
co-authored by Sisyphus
parent bc6a5461c1
commit 2dbb1486b0
7 changed files with 91 additions and 34 deletions
+4 -4
View File
@@ -166,10 +166,10 @@ func TestValidateImageBytes_Empty(t *testing.T) {
// TestValidateImageBytes_AllSupportedFormats verifies every supported format returns a non-empty extension.
func TestValidateImageBytes_AllSupportedFormats(t *testing.T) {
tests := []struct {
name string
data []byte
wantExt string
wantErr bool
name string
data []byte
wantExt string
wantErr bool
}{
{"JPEG", []byte{0xff, 0xd8, 0xff, 0xe0, 0x00, 0x10, 0x4a, 0x46, 0x49, 0x46, 0x00, 0x01}, ".jpg", false},
{"PNG", []byte{0x89, 'P', 'N', 'G', '\r', '\n', 0x1a, '\n', 0, 0, 0, 0}, ".png", false},