Made debug configurable