Updated for current definition of validateObject