def db(self):
        """
        Get a loaded database session
        """
        if self.database is NotImplemented:
            self.database = Session

        return self.database
Get a loaded database session