Skip to content

Commit 2387bb1

Browse files
authored
Merge pull request #2 from itk-dev/feature/os2forms-audit-fixes
Feature/os2forms audit fixes
2 parents eb4d55b + afa495f commit 2387bb1

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

src/Plugin/os2web/DataLookup/DataLookupBase.php

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,10 @@
33
namespace Drupal\os2web_datalookup\Plugin\os2web\DataLookup;
44

55
use Drupal\Core\Form\FormStateInterface;
6+
use Drupal\Core\Plugin\ContainerFactoryPluginInterface;
67
use Drupal\Core\Plugin\PluginBase;
78
use Drupal\os2web_audit\Service\Logger;
9+
use Symfony\Component\DependencyInjection\ContainerInterface;
810

911
/**
1012
* Provides a base class for image effects.
@@ -16,7 +18,7 @@
1618
* @see \Drupal\image\ImageEffectManager
1719
* @see plugin_api
1820
*/
19-
abstract class DataLookupBase extends PluginBase implements DataLookupInterface {
21+
abstract class DataLookupBase extends PluginBase implements DataLookupInterface, ContainerFactoryPluginInterface {
2022

2123
/**
2224
* Plugin readiness flag.
@@ -46,6 +48,18 @@ public function __construct(
4648
$this->setConfiguration($configuration);
4749
}
4850

51+
/**
52+
* {@inheritdoc}
53+
*/
54+
public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) {
55+
return new static(
56+
$configuration,
57+
$plugin_id,
58+
$plugin_definition,
59+
$container->get('os2web_audit.logger'),
60+
);
61+
}
62+
4963
/**
5064
* {@inheritdoc}
5165
*/

0 commit comments

Comments
 (0)