Fixed bug where USER environment variable is not resolved.