Added support for adding undefined objects