Removing deprecated functions.

parent 51e0081e
......@@ -184,20 +184,6 @@ class XmlSitemapWriter extends \XMLWriter {
}
}
/**
* Writes an full XML sitemap element tag.
*
* @param string $name
* The element name.
* @param array $element
* An array of the elements properties and values.
*
* @deprecated Use \Drupal\xmlsitemap\XmlSitemapWriter::writeElement().
*/
public function writeSitemapElement($name, array $element) {
$this->writeElement($name, $element);
}
/**
* Writes full element tag including support for nested elements.
*
......
......@@ -966,46 +966,6 @@ function xmlsitemap_link_bundle_delete($entity, $bundle, $delete_links = TRUE) {
xmlsitemap_get_link_info(NULL, TRUE);
}
/**
* Checks access for a bundle.
*
* @param string $entity
* Entity type id.
* @param string $bundle
* Bundle id.
*
* @return bool
* If TRUE, access is allowed, FALSE otherwise.
*
* @deprecated in xmlsitemap:8.x-1.1 and is removed from xmlsitemap:2.0.0.
*
* @see https://www.drupal.org/project/xmlsitemap/issues/3156088
*/
function xmlsitemap_link_bundle_access($entity, $bundle = NULL) {
@trigger_error(__FUNCTION__ . ' is deprecated in xmlsitemap:8.x-1.1 and will be removed in xmlsitemap:2.0.0. See https://www.drupal.org/project/xmlsitemap/issues/3156088', E_USER_DEPRECATED);
return FALSE;
}
/**
* Get path of a bundle.
*
* @param string $entity
* Entity type id.
* @param string $bundle
* Bundle id.
*
* @return mixed
* Path of bundle, or FALSE if it does not exist.
*
* @deprecated in xmlsitemap:8.x-1.1 and is removed from xmlsitemap:2.0.0.
*
* @see https://www.drupal.org/project/xmlsitemap/issues/3156088
*/
function xmlsitemap_get_bundle_path($entity, $bundle) {
@trigger_error(__FUNCTION__ . ' is deprecated in xmlsitemap:8.x-1.1 and will be removed in xmlsitemap:2.0.0. See https://www.drupal.org/project/xmlsitemap/issues/3156088', E_USER_DEPRECATED);
return FALSE;
}
/**
* Implements hook_entity_bundle_rename().
*/
......@@ -2283,35 +2243,6 @@ function xmlsitemap_get_current_chunk(XmlSitemapInterface $sitemap, Request $req
}
}
/**
* Creates a response reading the sitemap file and adding content to response.
*
* @param \Symfony\Component\HttpFoundation\Response $response
* Response object.
* @param string $file
* File uri.
* @param array $headers
* Headers of the response.
*
* @return \Symfony\Component\HttpFoundation\BinaryFileResponse
* The sitemap response object.
*
* @throws \Symfony\Component\HttpKernel\Exception\NotFoundHttpException
* If the sitemap is not found or the sitemap file is not readable.
*
* @deprecated in xmlsitemap:8.x-1.0 and is removed from xmlsitemap:2.0.0. Use
* \Drupal\xmlsitemap\Controller\XmlSitemapController::getSitemapResponse()
* instead.
*
* @see https://www.drupal.org/project/xmlsitemap/issues/2869214
*/
function xmlsitemap_output_file(Response $response, $file, array $headers = []) {
@trigger_error(__FUNCTION__ . ' is deprecated in xmlsitemap:8.x-1.0 and will be removed in xmlsitemap:2.0.0. Use \Drupal\xmlsitemap\Controller\XmlSitemapController::getSitemapResponse. See https://www.drupal.org/project/xmlsitemap/issues/2869214', E_USER_DEPRECATED);
/** @var \Drupal\xmlsitemap\Controller\XmlSitemapController $controller */
$controller = \Drupal::classResolver(XmlSitemapController::class);
return $controller->getSitemapResponse($file, \Drupal::request(), $headers + $response->headers->all());
}
/**
* Get Blurb.
*
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment