bots: Don't allow embedded bots bot type in production.

This is important for making it easy for us to merge code related to
UI for embedded bots now, without enabling them in the production UI.
This commit is contained in:
Tim Abbott 2017-11-30 15:27:57 -08:00
parent eebef9e9de
commit 2310794451
1 changed files with 4 additions and 2 deletions

View File

@ -494,12 +494,14 @@ class UserProfile(AbstractBaseUser, PermissionsMixin):
DEFAULT_BOT,
INCOMING_WEBHOOK_BOT,
OUTGOING_WEBHOOK_BOT,
EMBEDDED_BOT,
]
if settings.DEVELOPMENT:
# Embedded bots are not yet enabled in production.
ALLOWED_BOT_TYPES.append(EMBEDDED_BOT)
SERVICE_BOT_TYPES = [
OUTGOING_WEBHOOK_BOT,
EMBEDDED_BOT
EMBEDDED_BOT,
]
# Fields from models.AbstractUser minus last_name and first_name,