small style fixes and typo

This commit is contained in:
Mouse Reeve 2020-09-30 19:57:25 -07:00
parent f72d59955e
commit fe83f5d442

View file

@ -5,7 +5,8 @@ import requests
from django.core.files.base import ContentFile from django.core.files.base import ContentFile
from bookwyrm import models from bookwyrm import models
from .abstract_connector import AbstractConnector, ConnectorException, SearchResult, Mapping from .abstract_connector import AbstractConnector, SearchResult, Mapping
from .abstract_connector import ConnectorException
from .abstract_connector import update_from_mappings from .abstract_connector import update_from_mappings
from .abstract_connector import get_date, get_data from .abstract_connector import get_date, get_data
from .openlibrary_languages import languages from .openlibrary_languages import languages
@ -90,7 +91,7 @@ class Connector(AbstractConnector):
try: try:
key = data['works'][0]['key'] key = data['works'][0]['key']
except (IndexError, KeyError): except (IndexError, KeyError):
raise ConnectorException('No work found foredition') raise ConnectorException('No work found for edition')
url = '%s/%s' % (self.books_url, key) url = '%s/%s' % (self.books_url, key)
return get_data(url) return get_data(url)