Wrong callback was being called