I get no implicit conversion of Pathname into String sometimes

Adding to_s fixes the issue.