Fix isBinaryFile issue