mirror of
https://github.com/bookwyrm-social/bookwyrm.git
synced 2024-11-22 17:41:08 +00:00
Update forms.py
This commit is contained in:
parent
495af09c4c
commit
82aacf8f2a
1 changed files with 2 additions and 0 deletions
|
@ -238,6 +238,7 @@ class FileLinkForm(CustomForm):
|
|||
if models.LinkDomain.objects.filter(domain=domain).exists():
|
||||
status = models.LinkDomain.objects.get(domain=domain).status
|
||||
if status == "blocked":
|
||||
# pylint: disable=line-too-long
|
||||
self.add_error(
|
||||
"url",
|
||||
_(
|
||||
|
@ -247,6 +248,7 @@ class FileLinkForm(CustomForm):
|
|||
elif models.FileLink.objects.filter(
|
||||
url=url, book=book, filetype=filetype
|
||||
).exists():
|
||||
# pylint: disable=line-too-long
|
||||
self.add_error(
|
||||
"url",
|
||||
_(
|
||||
|
|
Loading…
Reference in a new issue