Commit 81f886ab authored by Sam152's avatar Sam152 Committed by Sam152
Browse files

Issue #2646530 by Sam152: Remove the ColorboxAttachment::alreadyAdded flag

parent f1d4587b
......@@ -35,13 +35,6 @@ class ColorboxAttachment implements PageAttachmentInterface {
*/
protected $settings;
/**
* If colorbox has already been added to the page.
*
* @var bool
*/
static $alreadyAdded = FALSE;
/**
* Create an instance of ColorboxAttachment.
*/
......@@ -55,15 +48,13 @@ class ColorboxAttachment implements PageAttachmentInterface {
* {@inheritdoc}
*/
public function isApplicable() {
return !drupal_installation_attempted() && !static::$alreadyAdded && $this->activation->isActive();
return !drupal_installation_attempted() && $this->activation->isActive();
}
/**
* {@inheritdoc}
*/
public function attach(array &$page) {
static::$alreadyAdded = TRUE;
if ($this->settings->get('custom.activate')) {
$js_settings = array(
'transition' => $this->settings->get('custom.transition_type'),
......
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