fixed path joining to not use static variable