mirror of
https://github.com/makeplane/plane.git
synced 2026-08-29 10:08:51 +02:00
fix: Use APP_DOMAIN env var for bot user email (#9262)
* fix: Use APP_DOMAIN env var for bot user email instead of hardcoded plane.so Signed-off-by: okxint <cashmein.eth@gmail.com> * use settings.WEB_URL instead of APP_DOMAIN env var for bot email domain --------- Signed-off-by: okxint <cashmein.eth@gmail.com>
This commit is contained in:
@@ -10,6 +10,7 @@ import uuid
|
||||
from typing import Dict
|
||||
import logging
|
||||
from datetime import timedelta
|
||||
from urllib.parse import urlparse
|
||||
|
||||
# Django imports
|
||||
from django.conf import settings
|
||||
@@ -526,7 +527,7 @@ def workspace_seed(workspace_id: uuid.UUID) -> None:
|
||||
last_name="",
|
||||
is_bot=True,
|
||||
bot_type=BotTypeEnum.WORKSPACE_SEED,
|
||||
email=f"bot_user_{workspace.id}@plane.so",
|
||||
email=f"bot_user_{workspace.id}@{urlparse(settings.WEB_URL or 'https://plane.so').hostname or 'plane.so'}",
|
||||
password=make_password(uuid.uuid4().hex),
|
||||
is_password_autoset=True,
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user