Skip to content

Commit

Permalink
Update database stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
webhead1104 committed May 6, 2024
1 parent adf5db7 commit bd2a6fa
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 34 deletions.
1 change: 1 addition & 0 deletions src/main/java/net/cytonic/cytosis/Cytosis.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import net.cytonic.cytosis.commands.CommandHandler;
import net.cytonic.cytosis.config.CytosisSettings;
import net.cytonic.cytosis.data.DatabaseManager;
import net.cytonic.cytosis.events.EventHandler;
import net.cytonic.cytosis.events.ServerEventListeners;
import net.cytonic.cytosis.files.FileManager;
Expand Down
34 changes: 0 additions & 34 deletions src/main/java/net/cytonic/cytosis/DatabaseManager.java

This file was deleted.

24 changes: 24 additions & 0 deletions src/main/java/net/cytonic/cytosis/data/DatabaseManager.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
package net.cytonic.cytosis.data;

import net.cytonic.cytosis.logging.Logger;

public class DatabaseManager {

private Database database;

public DatabaseManager() {
}

public void shutdown() {
database.disconnect();
Logger.info("Good night!");
}

public void setupDatabase() {
database = new Database();
database.connect();
database.createChatTable();
}

public Database getDatabase() {return database;}
}

0 comments on commit bd2a6fa

Please sign in to comment.