Skip to content

Commit

Permalink
bug fix type variable
Browse files Browse the repository at this point in the history
  • Loading branch information
mediafoks committed Nov 6, 2024
1 parent 9e7dce3 commit 34ce1e6
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 11 deletions.
2 changes: 1 addition & 1 deletion ksopengraph.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<copyright>Copyright (C) 2024 Sergey Kuznetsov</copyright>
<license>MIT</license>
<authorEmail>mediafoks@google.com</authorEmail>
<version>2.0.0</version>
<version>2.0.1</version>
<description>PLG_CONTENT_KS_OPEN_GRAPH_XML_DESCRIPTION</description>
<namespace path="src">Joomla\Plugin\Content\KsOpenGraph</namespace>
<files>
Expand Down
2 changes: 1 addition & 1 deletion services/provider.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
*
* @return void
*
* @since 2.0.0
* @since 2.0.1
*/
public function register(Container $container)
{
Expand Down
15 changes: 8 additions & 7 deletions src/Extension/KsOpenGraph.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* @version 2.0.0
* @version 2.0.1
* @package ksopengraph (plugin)
* @author Sergey Kuznetsov - mediafoks@google.com
* @copyright Copyright (c) 2024 Sergey Kuznetsov
Expand All @@ -27,6 +27,7 @@ final class KsOpenGraph extends CMSPlugin implements SubscriberInterface

public $pluginNr = 0;
public $twitterEnable = 0;
public $type = 1;

public static function getSubscribedEvents(): array
{
Expand Down Expand Up @@ -224,11 +225,11 @@ public function onContentPrepare(ContentPrepareEvent $event): void
$this->pluginNr = 1;
} else return;

$this->renderTag('og:site_name', $config->get('sitename'), $type);
$this->renderTag('og:title', $thisTitle, $type);
$this->renderTag('og:description', $this->catStr($thisDescription), $type);
$this->renderTag('og:url', Uri::current(), $type);
$this->renderTag('og:image', $this->setImage($this->realCleanImageURL($thisImage)), $type);
$this->renderTag('og:type', $thisOgType, $type);
$this->renderTag('og:site_name', $config->get('sitename'), $this->type);
$this->renderTag('og:title', $thisTitle, $this->type);
$this->renderTag('og:description', $this->catStr($thisDescription), $this->type);
$this->renderTag('og:url', Uri::current(), $this->type);
$this->renderTag('og:image', $this->setImage($this->realCleanImageURL($thisImage)), $this->type);
$this->renderTag('og:type', $thisOgType, $this->type);
}
}
4 changes: 2 additions & 2 deletions update.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
<element>ksopengraph</element>
<type>plugin</type>
<folder>content</folder>
<version>2.0.0</version>
<version>2.0.1</version>
<downloads>
<downloadurl type="full" format="zip">https://github.com/mediafoks/plg_content_ksopengraph/archive/refs/tags/v2.0.0.zip</downloadurl>
<downloadurl type="full" format="zip">https://github.com/mediafoks/plg_content_ksopengraph/archive/refs/tags/v2.0.1.zip</downloadurl>
</downloads>
<tags>
<tag>stable</tag>
Expand Down

0 comments on commit 34ce1e6

Please sign in to comment.