diff --git a/core/modules/aggregator/lib/Drupal/aggregator/Form/SettingsForm.php b/core/modules/aggregator/lib/Drupal/aggregator/Form/SettingsForm.php
index fafff13..3d753c2 100644
--- a/core/modules/aggregator/lib/Drupal/aggregator/Form/SettingsForm.php
+++ b/core/modules/aggregator/lib/Drupal/aggregator/Form/SettingsForm.php
@@ -7,9 +7,11 @@
namespace Drupal\aggregator\Form;
-use Drupal\system\SystemConfigFormBase;
+use Drupal\Core\Form\FormInterface;
use Drupal\Core\Config\ConfigFactory;
+use Drupal\system\SystemConfigFormBase;
use Drupal\aggregator\Plugin\AggregatorPluginManager;
+use Drupal\Component\Utility\String;
use Symfony\Component\DependencyInjection\ContainerInterface;
/**
@@ -64,7 +66,7 @@ public function __construct(ConfigFactory $config_factory, AggregatorPluginManag
// Get all available fetcher, parser and processor definitions.
foreach (array('fetcher', 'parser', 'processor') as $type) {
foreach ($this->managers[$type]->getDefinitions() as $id => $definition) {
- $this->definitions[$type][$id] = format_string('@title @description', array('@title' => $definition['title'], '@description' => $definition['description']));
+ $this->definitions[$type][$id] = String::format('@title @description', array('@title' => $definition['title'], '@description' => $definition['description']));
}
}
}
@@ -148,9 +150,11 @@ public function buildForm(array $form, array &$form_state) {
$active = $config->get($type);
if (array_key_exists($active, $this->definitions[$type])) {
$instance = $this->managers[$type]->createInstance($active);
- $form = $instance->buildForm($form, $form_state);
- // Store the instance for validate and submit handlers.
- $this->instances[] = $instance;
+ if ($instance instanceof FormInterface) {
+ $form = $instance->buildForm($form, $form_state);
+ // Store the instance for validate and submit handlers.
+ $this->instances[] = $instance;
+ }
}
}
@@ -160,9 +164,11 @@ public function buildForm(array $form, array &$form_state) {
foreach ($this->definitions['processor'] as $id => $definition) {
if (in_array($id, $config->get('processors'))) {
$instance = $this->managers['processor']->createInstance($id);
- $form = $instance->buildForm($form, $form_state);
- // Store the instance for validate and submit handlers.
- $this->instances[] = $instance;
+ if ($instance instanceof FormInterface) {
+ $form = $instance->buildForm($form, $form_state);
+ // Store the instance for validate and submit handlers.
+ $this->instances[] = $instance;
+ }
}
}
return parent::buildForm($form, $form_state);
diff --git a/core/modules/aggregator/lib/Drupal/aggregator/Plugin/FetcherInterface.php b/core/modules/aggregator/lib/Drupal/aggregator/Plugin/FetcherInterface.php
index 3069fa0..da1377d 100644
--- a/core/modules/aggregator/lib/Drupal/aggregator/Plugin/FetcherInterface.php
+++ b/core/modules/aggregator/lib/Drupal/aggregator/Plugin/FetcherInterface.php
@@ -7,7 +7,6 @@
namespace Drupal\aggregator\Plugin;
-use Drupal\Core\Form\FormInterface;
use Drupal\aggregator\Plugin\Core\Entity\Feed;
/**
@@ -19,7 +18,7 @@
* parser; and finally, it is passed to all active processors, which manipulate
* or store the data.
*/
-interface FetcherInterface extends FormInterface {
+interface FetcherInterface {
/**
* Downloads feed data.
diff --git a/core/modules/aggregator/lib/Drupal/aggregator/Plugin/ParserInterface.php b/core/modules/aggregator/lib/Drupal/aggregator/Plugin/ParserInterface.php
index 19ee80a..317b806 100644
--- a/core/modules/aggregator/lib/Drupal/aggregator/Plugin/ParserInterface.php
+++ b/core/modules/aggregator/lib/Drupal/aggregator/Plugin/ParserInterface.php
@@ -7,7 +7,6 @@
namespace Drupal\aggregator\Plugin;
-use Drupal\Core\Form\FormInterface;
use Drupal\aggregator\Plugin\Core\Entity\Feed;
/**
@@ -20,7 +19,7 @@
* manipulate or store the data.
*
*/
-interface ParserInterface extends FormInterface {
+interface ParserInterface {
/**
* Parses feed data.
diff --git a/core/modules/aggregator/lib/Drupal/aggregator/Plugin/ProcessorInterface.php b/core/modules/aggregator/lib/Drupal/aggregator/Plugin/ProcessorInterface.php
index ab33925..844abb0 100644
--- a/core/modules/aggregator/lib/Drupal/aggregator/Plugin/ProcessorInterface.php
+++ b/core/modules/aggregator/lib/Drupal/aggregator/Plugin/ProcessorInterface.php
@@ -7,7 +7,6 @@
namespace Drupal\aggregator\Plugin;
-use Drupal\Core\Form\FormInterface;
use Drupal\aggregator\Plugin\Core\Entity\Feed;
/**
@@ -19,7 +18,7 @@
* parser; and finally, it is passed to all active processors that manipulate or
* store the data.
*/
-interface ProcessorInterface extends FormInterface {
+interface ProcessorInterface {
/**
* Processes feed data.