mirror of
https://github.com/bookwyrm-social/bookwyrm.git
synced 2024-11-27 03:51:08 +00:00
Style cleanup.
This commit is contained in:
parent
976e7ddf79
commit
d43c513d19
1 changed files with 3 additions and 5 deletions
|
@ -22,7 +22,6 @@ def unquote_string(text):
|
|||
match = re.match(r'="([^"]*)"', text)
|
||||
if match:
|
||||
return match.group(1)
|
||||
else:
|
||||
return text
|
||||
|
||||
|
||||
|
@ -36,7 +35,7 @@ def construct_search_term(title, author):
|
|||
return ' '.join([title, author])
|
||||
|
||||
|
||||
class GoodreadsCsv(object):
|
||||
class GoodreadsCsv:
|
||||
''' define a goodreads csv '''
|
||||
def __init__(self, csv_file):
|
||||
self.reader = csv.DictReader(csv_file)
|
||||
|
@ -51,7 +50,7 @@ class GoodreadsCsv(object):
|
|||
yield entry
|
||||
|
||||
|
||||
class GoodreadsItem(object):
|
||||
class GoodreadsItem:
|
||||
''' a processed line in a goodreads csv '''
|
||||
def __init__(self, line):
|
||||
self.line = line
|
||||
|
@ -94,4 +93,3 @@ class GoodreadsItem(object):
|
|||
|
||||
def __str__(self):
|
||||
return "{} by {}".format(self.line['Title'], self.line['Author'])
|
||||
|
||||
|
|
Loading…
Reference in a new issue