Fix to path expansion when parent is null