private void ValidateSession(ISession session) { if (session == null) { throw new RuntimeException("Session variable not set. " + "Did you forget to connect and set a repository?"); } }