Fix path issue when $source is "".