Added logging, fixed UI