mirror of
https://github.com/bookwyrm-social/bookwyrm.git
synced 2024-11-26 11:31: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():
|
if models.LinkDomain.objects.filter(domain=domain).exists():
|
||||||
status = models.LinkDomain.objects.get(domain=domain).status
|
status = models.LinkDomain.objects.get(domain=domain).status
|
||||||
if status == "blocked":
|
if status == "blocked":
|
||||||
|
# pylint: disable=line-too-long
|
||||||
self.add_error(
|
self.add_error(
|
||||||
"url",
|
"url",
|
||||||
_(
|
_(
|
||||||
|
@ -247,6 +248,7 @@ class FileLinkForm(CustomForm):
|
||||||
elif models.FileLink.objects.filter(
|
elif models.FileLink.objects.filter(
|
||||||
url=url, book=book, filetype=filetype
|
url=url, book=book, filetype=filetype
|
||||||
).exists():
|
).exists():
|
||||||
|
# pylint: disable=line-too-long
|
||||||
self.add_error(
|
self.add_error(
|
||||||
"url",
|
"url",
|
||||||
_(
|
_(
|
||||||
|
|
Loading…
Reference in a new issue