Cleaned up some stuff
Fixed error checking on path names