Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Attribute Error: 'NoneType' object has no attribute 'id' #145

Open
imsanjoykb opened this issue Dec 4, 2021 · 0 comments
Open

Attribute Error: 'NoneType' object has no attribute 'id' #145

imsanjoykb opened this issue Dec 4, 2021 · 0 comments

Comments

@imsanjoykb
Copy link
Owner

def str(self):
"""
String for representing the Model object
"""
if self.book:
return '%s (%s)' %(self.id, self.book.title))
else:
return '%s (%s)' %(self.id, self.imprint)) # add some other value that you want here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant