Skip to content

Commit

Permalink
requested changes
Browse files Browse the repository at this point in the history
  • Loading branch information
Emrys committed Oct 2, 2020
1 parent b08bf44 commit e5e9e82
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
1 change: 0 additions & 1 deletion requirements-dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ pytest==4.6.9 ; python_version < '3.0'
pytest==5.3.5 ; python_version >= '3.0'
pytest-cov==2.8.1
coveralls==1.11.1
nose == 1.3.7

# Documentation
Sphinx==1.8.5 ; python_version < '3.5'
Expand Down
2 changes: 1 addition & 1 deletion skosprovider_getty/providers.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ def get_by_uri(self, uri, change_notes=False):

id = uri_to_id(uri)

return self.get_by_id(id, change_notes)
return self.get_by_id(id, change_notes) if 'vocab.getty.edu' in uri else None

def find(self, query, **kwargs):
'''Find concepts that match a certain query.
Expand Down
2 changes: 2 additions & 0 deletions tests/test_providers.py
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,8 @@ def test_get_by_uri_invalid(self):
# Default GettyProvider is an AAT provider
concept = GettyProvider({'id': 'AAT'}).get_by_uri('urn:skosprovider:5')
self.assertFalse(concept)
concept = GettyProvider({'id': 'AAT'}).get_by_uri('https://id.erfgoed.net/thesauri/materialen/7')
self.assertFalse(concept)

def test_get_by_id_tgn(self):
concept = TGNProvider({'id': 'TGN'}).get_by_id('1000063')
Expand Down

0 comments on commit e5e9e82

Please sign in to comment.