made isValid Static