# wordpress-seo/18.6/src/routes/abstract-action-route.php

Yoast SEO – Advanced SEO with real-time guidance and built-in AI, version 18.6. 31 lines.

- Page: https://pluginprobe.com/plugins/wordpress-seo/18.6/code/src/routes/abstract-action-route.php
- Raw: https://pluginprobe.com/plugins/wordpress-seo/18.6/raw/src/routes/abstract-action-route.php
- Modified: 2021-11-16T15:11:00+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/wordpress-seo/18.6/code/src/routes/abstract-action-route.php#L10-L20`.

```php
<?php

namespace Yoast\WP\SEO\Routes;

use WP_REST_Response;

/**
 * Abstract_Action_Route class.
 *
 * Abstract class for action routes.
 */
abstract class Abstract_Action_Route implements Route_Interface {

	/**
	 * Responds to an indexing request.
	 *
	 * @param array  $objects  The objects that have been indexed.
	 * @param string $next_url The url that should be called to continue reindexing. False if done.
	 *
	 * @return WP_REST_Response The response.
	 */
	protected function respond_with( $objects, $next_url ) {
		return new WP_REST_Response(
			[
				'objects'  => $objects,
				'next_url' => $next_url,
			]
		);
	}
}

```
