Pass options.parentResources by copy instead of reference.