Fixing issues with application using BASEPATH

Fixes #217