added some console logging