fixed problem with required keys not being treated as specified