diff --git a/internal/entity/lens_test.go b/internal/entity/lens_test.go index e512386eb..d3cddaead 100644 --- a/internal/entity/lens_test.go +++ b/internal/entity/lens_test.go @@ -17,7 +17,7 @@ func TestNewLens(t *testing.T) { lens := NewLens("", "") assert.Equal(t, "Unknown", lens.LensModel) assert.Equal(t, "", lens.LensMake) - assert.Equal(t, "zz", lens.LensSlug) + assert.Equal(t, UnknownLens.LensSlug, lens.LensSlug) assert.Equal(t, &UnknownLens, lens) }) } diff --git a/internal/entity/photo_location.go b/internal/entity/photo_location.go index 85b1793c6..ac4ece0c7 100644 --- a/internal/entity/photo_location.go +++ b/internal/entity/photo_location.go @@ -88,7 +88,7 @@ func (m *Photo) UpdateLocation(db *gorm.DB, geoApi string) (keywords []string, l m.PlaceID = UnknownPlace.ID } - if m.Place != nil && (m.PhotoCountry == "" || m.PhotoCountry == "zz") { + if m.Place != nil && (m.PhotoCountry == "" || m.PhotoCountry == UnknownCountry.Code()) { m.PhotoCountry = m.Place.LocCountry }