This should be changed to `$view->getPath($itemSource)` and then use `basename($path)` to get the name