mirror of
https://gitlab.crans.org/mediatek/med.git
synced 2025-07-07 16:28:32 +02:00
Fix openlibrary scrap, fix linters
This commit is contained in:
@ -8,7 +8,6 @@ Based on https://github.com/secnot/django-isbn-field
|
||||
|
||||
from django.core.exceptions import ValidationError
|
||||
from django.utils.translation import ugettext_lazy as _
|
||||
from stdnum import isbn
|
||||
|
||||
|
||||
def isbn_validator(raw_isbn):
|
||||
@ -21,7 +20,7 @@ def isbn_validator(raw_isbn):
|
||||
if len(isbn_to_check) != 10 and len(isbn_to_check) != 13:
|
||||
raise ValidationError(_('Invalid ISBN: Wrong length'))
|
||||
|
||||
#if not isbn.is_valid(isbn_to_check):
|
||||
# if not isbn.is_valid(isbn_to_check):
|
||||
# raise ValidationError(_('Invalid ISBN: Failed checksum'))
|
||||
|
||||
if isbn_to_check != isbn_to_check.upper():
|
||||
|
Reference in New Issue
Block a user