adds logging / debug