_logManager cannot be set on RouterContexts (i.e. when running as plugin)

This commit is contained in:
Zlatin Balevsky
2019-11-30 13:26:20 +00:00
parent b2841ee9ab
commit 61baa53076

View File

@@ -150,10 +150,12 @@ public class Core {
}
if (!props.embeddedRouter) {
log.info "Initializing I2P context"
I2PAppContext.getGlobalContext().logManager()
I2PAppContext.getGlobalContext()._logManager = new MuWireLogManager()
router = null
if (!(I2PAppContext.getGlobalContext() instanceof RouterContext)) {
log.info "Initializing I2P context"
I2PAppContext.getGlobalContext().logManager()
I2PAppContext.getGlobalContext()._logManager = new MuWireLogManager()
router = null
}
} else {
log.info("launching embedded router")
Properties routerProps = new Properties()