Fix getting filename