The lstrip (left trim) call is to make sure that there are no slashes at the beginning of file paths.