From dfafe9a353bd1d4dcbbde691b9c8cda2533f47a3 Mon Sep 17 00:00:00 2001 From: Russ Cox Date: Wed, 24 Jun 2009 20:12:50 -0700 Subject: style police: parens in if, for, switch, range R=r DELTA=32 (0 added, 3 deleted, 29 changed) OCL=30718 CL=30725 --- src/pkg/http/client_test.go | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'src/pkg/http/client_test.go') diff --git a/src/pkg/http/client_test.go b/src/pkg/http/client_test.go index ca4235879..919e556e4 100644 --- a/src/pkg/http/client_test.go +++ b/src/pkg/http/client_test.go @@ -27,10 +27,7 @@ func TestClient(t *testing.T) { if err != nil { t.Errorf("Error fetching URL: %v", err); - } else { - s := string(b); - if (!strings.HasPrefix(s, "User-agent:")) { - t.Errorf("Incorrect page body (did not begin with User-agent): %q", s); - } + } else if s := string(b); !strings.HasPrefix(s, "User-agent:") { + t.Errorf("Incorrect page body (did not begin with User-agent): %q", s); } } -- cgit v1.2.3