moved code to reference comments