Added Dan's changes