Added many more statements for debugging