Added better logging visible only with debug enabled