You are here

public function DisqusWidget::__construct in Disqus 8

Constructs a WidgetBase object.

Parameters

string $plugin_id: The plugin_id for the widget.

mixed $plugin_definition: The plugin implementation definition.

\Drupal\Core\Field\FieldDefinitionInterface $field_definition: The definition of the field to which the widget is associated.

array $settings: The widget settings.

array $third_party_settings: Any third party settings.

Overrides WidgetBase::__construct

File

src/Plugin/Field/FieldWidget/DisqusWidget.php, line 36

Class

DisqusWidget
Plugin implementation of the Disqus comments widget.

Namespace

Drupal\disqus\Plugin\Field\FieldWidget

Code

public function __construct($plugin_id, $plugin_definition, FieldDefinitionInterface $field_definition, array $settings, AccountInterface $current_user) {
  parent::__construct($plugin_id, $plugin_definition, $field_definition, $settings, []);
  $this->currentUser = $current_user;
}