Confirm email views
This commit is contained in:
@ -31,6 +31,7 @@ class SiteSettings(models.Model):
|
||||
# registration
|
||||
allow_registration = models.BooleanField(default=True)
|
||||
allow_invite_requests = models.BooleanField(default=True)
|
||||
require_confirm_email = models.BooleanField(default=True)
|
||||
|
||||
# images
|
||||
logo = models.ImageField(upload_to="logos/", null=True, blank=True)
|
||||
|
@ -26,11 +26,13 @@ from .base_model import BookWyrmModel, DeactivationReason, new_access_code
|
||||
from .federated_server import FederatedServer
|
||||
from . import fields, Review
|
||||
|
||||
|
||||
def site_link():
|
||||
"""helper for generating links to the site"""
|
||||
protocol = "https" if USE_HTTPS else "http"
|
||||
return f"{protocol}://{DOMAIN}"
|
||||
|
||||
|
||||
class User(OrderedCollectionPageMixin, AbstractUser):
|
||||
"""a user who wants to read books"""
|
||||
|
||||
@ -218,7 +220,7 @@ class User(OrderedCollectionPageMixin, AbstractUser):
|
||||
self.following.order_by("-updated_date").all(),
|
||||
remote_id=remote_id,
|
||||
id_only=True,
|
||||
**kwargs
|
||||
**kwargs,
|
||||
)
|
||||
|
||||
def to_followers_activity(self, **kwargs):
|
||||
@ -228,7 +230,7 @@ class User(OrderedCollectionPageMixin, AbstractUser):
|
||||
self.followers.order_by("-updated_date").all(),
|
||||
remote_id=remote_id,
|
||||
id_only=True,
|
||||
**kwargs
|
||||
**kwargs,
|
||||
)
|
||||
|
||||
def to_activity(self, **kwargs):
|
||||
|
Reference in New Issue
Block a user