fixed problem with restoring embedded objects, added generics get_object security check