Overriding filter and isValid for file input