Changed: Changed pointers to references in paramaters