constPATH_DOES_NOT_EXIST="The path @faulty_path has been omitted from the XML sitemap, as it does not exist.";
constPATH_DOES_NOT_EXIST_OR_NO_ACCESS="The path @faulty_path has been omitted from the XML sitemap as it either does not exist, or it is not accessible to anonymous users.";
constPATH_DOES_NOT_EXIST_OR_NO_ACCESS="The path @path has been omitted from the XML sitemap as it either does not exist, or it is not accessible to anonymous users.";
constBATCH_INIT_MESSAGE='Initializing batch...';
constBATCH_ERROR_MESSAGE='An error has occurred. This may result in an incomplete XML sitemap.';
constBATCH_PROGRESS_MESSAGE='Processing @current out of @total link types.';
...
...
@@ -148,7 +147,7 @@ class Batch {
foreach($entitiesas$entity_id=>$entity){
if(self::isBatch($batch_info)){
self::setCurrentId($entity_id,$context);//todo: move outside of this loop
self::setCurrentId($entity_id,$context);
}
// Overriding entity settings if it has been overridden on entity edit page...
...
...
@@ -244,8 +243,9 @@ class Batch {
if(self::isBatch($batch_info)){
self::setCurrentId($i,$context);
}
if(!\Drupal::service('path.validator')->isValid($custom_path['path'])){//todo: Change to different function, as this also checks if current user has access. The user however varies depending if process was started from the web interface or via cron/drush.
'#description'=>$this->t('If unchecked, the sitemap will include links to all content translation variants, even when the content has not been translated yet. If checked, only links to the translated content are included.'),
'#description'=>$this->t('If checked, only links to the translated content will be included, otherwise the sitemap will include links to all content translation variants, even when the content has not been translated yet.'),
$form_state->setErrorByName('',$this->t("The value of the <em>Maximum links in a sitemap</em> field must be empty, or a positive integer greater than 0."));
$form_state->setErrorByName('max_links',$this->t("The value of the <em>Maximum links in a sitemap</em> field must be empty, or a positive integer greater than 0."));
$form_state->setErrorByName('',$this->t("The value of the <em>Refresh batch every n links</em> field must be a positive integer greater than 0."));
$form_state->setErrorByName('batch_process_limit',$this->t("The value of the <em>Refresh batch every n links</em> field must be a positive integer greater than 0."));
}
}
...
...
@@ -136,7 +136,6 @@ class SimplesitemapSettingsForm extends ConfigFormBase {