Fix issue with validFileOnly value