protected function persist_do_save( Collection $values ) {

		$added = array();

		foreach ( $values as $value ) {

			$new = ! $this->saver->get_pk( $value );

			// prevent recursion by excluding the relation that references this from being saved.
			$saved = $this->saver->save( $value, array( 'exclude_relations' => $this->other_attribute ) );
			$pk    = $this->saver->get_pk( $saved );

			if ( $new && $pk ) {
				$added[ $pk ] = $saved;

				$values->removeElement( $value );
			}

			$values->dont_remember( function ( Collection $collection ) use ( $saved, $pk ) {
				if ( ! $collection->contains( $saved ) ) {
					$collection->add( $saved );
				}
			} );
		}

		return $added;
	}