Fixes #29. If a previously cached UUID no longer exists, it will be invalidated and re-requested

This commit is contained in:
ErickSkrauch
2021-02-07 21:19:01 +01:00
parent 3bf6872f3e
commit 247499df6a
5 changed files with 50 additions and 3 deletions

View File

@@ -166,7 +166,7 @@ type EmptyResponse struct {
}
func (*EmptyResponse) Error() string {
return "200: Empty Response"
return "204: Empty Response"
}
func (*EmptyResponse) IsMojangError() bool {

View File

@@ -261,7 +261,7 @@ func TestUuidToTextures(t *testing.T) {
result, err := UuidToTextures("4566e69fc90748ee8d71d7ba5aa00d20", false)
assert.Nil(result)
assert.IsType(&EmptyResponse{}, err)
assert.EqualError(err, "200: Empty Response")
assert.EqualError(err, "204: Empty Response")
assert.Implements((*ResponseError)(nil), err)
})