mirror of
				https://github.com/TitanEmbeds/Titan.git
				synced 2025-11-03 23:37:09 +01:00 
			
		
		
		
	Inital postgresql implementation (#46)
This commit is contained in:
		
				
					committed by
					
						
						GitHub
					
				
			
			
				
	
			
			
			
						parent
						
							3a503c9bcb
						
					
				
				
					commit
					aa9075f484
				
			@@ -84,7 +84,7 @@ class Titan(discord.Client):
 | 
			
		||||
        )
 | 
			
		||||
 | 
			
		||||
        try:
 | 
			
		||||
            await self.database.connect(config["database-uri"] + "?charset=utf8mb4")
 | 
			
		||||
            await self.database.connect(config["database-uri"])
 | 
			
		||||
            self.database_connected = True
 | 
			
		||||
        except Exception:
 | 
			
		||||
            self.logger.error("Unable to connect to specified database!")
 | 
			
		||||
 
 | 
			
		||||
@@ -11,10 +11,10 @@ class Guilds(Base):
 | 
			
		||||
    chat_links = db.Column(db.Boolean())            # If users can post links
 | 
			
		||||
    bracket_links = db.Column(db.Boolean())         # If appending brackets to links to prevent embed
 | 
			
		||||
    mentions_limit = db.Column(db.Integer)          # If there is a limit on the number of mentions in a msg
 | 
			
		||||
    roles = db.Column(db.Text(length=4294967295))   # Guild Roles
 | 
			
		||||
    channels = db.Column(db.Text(length=4294967295))# Guild channels
 | 
			
		||||
    webhooks = db.Column(db.Text(length=4294967295))# Guild webhooks
 | 
			
		||||
    emojis = db.Column(db.Text(length=4294967295))  # Guild Emojis
 | 
			
		||||
    roles = db.Column(db.Text().with_variant(db.Text(length=4294967295), 'mysql'))   # Guild Roles
 | 
			
		||||
    channels = db.Column(db.Text().with_variant(db.Text(length=4294967295), 'mysql'))# Guild channels
 | 
			
		||||
    webhooks = db.Column(db.Text().with_variant(db.Text(length=4294967295), 'mysql'))# Guild webhooks
 | 
			
		||||
    emojis = db.Column(db.Text().with_variant(db.Text(length=4294967295), 'mysql'))  # Guild Emojis
 | 
			
		||||
    owner_id = db.Column(db.String(255))            # Snowflake of the owner
 | 
			
		||||
    icon = db.Column(db.String(255))                # The icon string, null if none
 | 
			
		||||
    discordio = db.Column(db.String(255))           # Custom Discord.io Invite Link
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user