예제 #1
0
        public override void RegisterPlugin(IrcConnection conn)
        {
            conn.RegisterCommand("!setmugshot", new Commands.SetMugshotCommand(conn));
            conn.RegisterCommand("!clearmugshot", new Commands.ClearMugshotCommand(conn));

            MugshotsContext.Initialise(conn.Config);
        }
예제 #2
0
 public static void Initialise(LumbricusConfiguration config)
 {
     if (db == null)
     {
         logger.Debug("Initialising MugshotsContext");
         db = new MugshotsContext();
     }
     else
     {
         logger.Debug("Skipping database initialisation; already connected");
     }
 }