Added debugging code