Changed mechanism to define the user's home directory.