Fix getPathView method when subdir is used inside controller directory