Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
function setValidity (exp) {
var expMonth = exp.month
var expYear = exp.year
var valid = (expMonth == null && expYear == null) || !!expMonth && !!expYear && !expiration.isPast(expMonth, expYear)
parentForm.$setValidity('ccExp', valid, $element)
}