updated virtual path handling for staging / production