diff --git a/map180/nzmap/nzmap.go b/map180/nzmap/nzmap.go index 9b554c4..babe53f 100644 --- a/map180/nzmap/nzmap.go +++ b/map180/nzmap/nzmap.go @@ -261,7 +261,7 @@ func (pts Points) Medium(b *bytes.Buffer) { yi, yf := math.Modf(v.Latitude*10 + 480.0) y := int(yi) - if x >= 0 && x < 150 && y >= 0 && y < 140 { + if x >= 0 && x < 150 && y >= 0 && y < 139 { p = nzMediumPts[int(x)][y] pp = nzMediumPts[x+1][y+1] pts[i].x = p.x + int(float64(pp.x-p.x)*xf) diff --git a/weft/assets_test.go b/weft/assets_test.go index 94fee48..57b748c 100644 --- a/weft/assets_test.go +++ b/weft/assets_test.go @@ -331,7 +331,7 @@ func TestCreateImportTag(t *testing.T) { "No nonce, one module file", "", map[string]*asset{ - "test.mjs": &asset{ + "test.mjs": { hashedPath: "/assets/js/hashprefix-test.mjs", sri: "sha384-abcd", }, @@ -351,11 +351,11 @@ func TestCreateImportTag(t *testing.T) { "Nonce present, two module files", "abcdefg", map[string]*asset{ - "test1.mjs": &asset{ + "test1.mjs": { hashedPath: "/assets/js/hashprefix-test1.mjs", sri: "sha384-efgh", }, - "test2.mjs": &asset{ + "test2.mjs": { hashedPath: "/assets/js/hashprefix-test2.mjs", sri: "sha384-ijkl", },