fixed issues with filename parsing