mirror of
				https://github.com/TitanEmbeds/Titan.git
				synced 2025-11-04 15:57:02 +01:00 
			
		
		
		
	Renamed webhook icon to guest icon for preperation of avatars in the client
This commit is contained in:
		@@ -6,7 +6,7 @@ class Cosmetics(db.Model):
 | 
			
		||||
    user_id = db.Column(db.String(255), nullable=False)             # Discord user id of user of cosmetics
 | 
			
		||||
    css = db.Column(db.Boolean(), nullable=False)                   # If they can create/edit custom CSS
 | 
			
		||||
    css_limit = db.Column(db.Integer, nullable=False, server_default="0") # Custom CSS Limit
 | 
			
		||||
    webhook_icon = db.Column(db.Boolean(), nullable=False, server_default=db.false()) # If they can set the webhook icon for all guilds
 | 
			
		||||
    guest_icon = db.Column(db.Boolean(), nullable=False, server_default=db.false()) # If they can set the guest icon for all guilds
 | 
			
		||||
    
 | 
			
		||||
    def __init__(self, user_id, **kwargs):
 | 
			
		||||
        self.user_id = user_id
 | 
			
		||||
@@ -21,7 +21,7 @@ class Cosmetics(db.Model):
 | 
			
		||||
        else:
 | 
			
		||||
            self.css_limit = 0
 | 
			
		||||
 | 
			
		||||
        if "webhook_icon" in kwargs:
 | 
			
		||||
            self.webhook_icon = kwargs["webhook_icon"]
 | 
			
		||||
        if "guest_icon" in kwargs:
 | 
			
		||||
            self.guest_icon = kwargs["guest_icon"]
 | 
			
		||||
        else:
 | 
			
		||||
            self.webhook_icon = False
 | 
			
		||||
            self.guest_icon = False
 | 
			
		||||
@@ -8,7 +8,7 @@ class Guilds(db.Model):
 | 
			
		||||
    unauth_users = db.Column(db.Boolean(), nullable=False, default=1)           # If allowed unauth users
 | 
			
		||||
    visitor_view = db.Column(db.Boolean(), nullable=False, default=0)           # If users are automatically "signed in" and can view chat
 | 
			
		||||
    webhook_messages = db.Column(db.Boolean(), nullable=False, default=0)       # Use webhooks to send messages instead of the bot
 | 
			
		||||
    webhook_icon = db.Column(db.String(255), default=None)                      # Webhook icon url, None if unset
 | 
			
		||||
    guest_icon = db.Column(db.String(255), default=None)                        # Guest icon url, None if unset
 | 
			
		||||
    chat_links = db.Column(db.Boolean(), nullable=False, default=1)             # If users can post links
 | 
			
		||||
    bracket_links = db.Column(db.Boolean(), nullable=False, default=1)          # If appending brackets to links to prevent embed
 | 
			
		||||
    mentions_limit = db.Column(db.Integer, nullable=False, default=11)          # If there is a limit on the number of mentions in a msg
 | 
			
		||||
@@ -26,7 +26,7 @@ class Guilds(db.Model):
 | 
			
		||||
        self.unauth_users = True # defaults to true
 | 
			
		||||
        self.visitor_view = False
 | 
			
		||||
        self.webhook_messages = False
 | 
			
		||||
        self.webhook_icon = None
 | 
			
		||||
        self.guest_icon = None
 | 
			
		||||
        self.chat_links = True
 | 
			
		||||
        self.bracket_links = True
 | 
			
		||||
        self.mentions_limit = -1 # -1 = unlimited mentions
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user