Skip to content
This repository has been archived by the owner on Apr 30, 2023. It is now read-only.

Commit

Permalink
version 1.4.5
Browse files Browse the repository at this point in the history
Summary: releasing version 1.4.5

Reviewed By: fbisaso

Differential Revision: D34894906

fbshipit-source-id: 7c3eb1a843e30faf8354d4de34e0c1fc205ee9b8
  • Loading branch information
Amir Harel authored and facebook-github-bot committed Mar 15, 2022
1 parent d3bd7f3 commit a39db7e
Show file tree
Hide file tree
Showing 13 changed files with 7 additions and 14 deletions.
4 changes: 2 additions & 2 deletions Helper/FBEHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -152,12 +152,12 @@ public function getSource()
/**
* @return string
*/
public function getPartnerAgent()
public function getPartnerAgent($with_magento_version = false)
{
return sprintf(
'%s-%s-%s',
$this->getSource(),
$this->getMagentoVersion(),
$with_magento_version ? $this->getMagentoVersion() : '0.0.0',
$this->getPluginVersion()
);
}
Expand Down
2 changes: 1 addition & 1 deletion Helper/ServerSideHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ public function sendEvent($event, $userDataArray = null)

$request = (new EventRequestAsync($this->fbeHelper->getPixelID()))
->setEvents($events)
->setPartnerAgent($this->fbeHelper->getPartnerAgent());
->setPartnerAgent($this->fbeHelper->getPartnerAgent(true));

$this->fbeHelper->log('Sending event ' . $event->getEventId());

Expand Down
2 changes: 1 addition & 1 deletion Test/Mftf/Data/PluginInfoData.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@
xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/DataGenerator/etc/dataProfileSchema.xsd">
<entity name="_pluginInfo" type="PluginInfo">
<data key="source">magento2</data>
<data key="pluginVersion">1.4.4</data>
<data key="pluginVersion">1.4.5</data>
</entity>
</entities>
2 changes: 1 addition & 1 deletion Test/Unit/Helper/FBEHelperTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ public function testCorrectPartnerAgent()
$this->objectManagerInterface->method('get')->willReturn($productMetadata);
$this->assertEquals(
sprintf('%s-%s-%s', $source, $magentoVersion, $pluginVersion),
$this->fbeHelper->getPartnerAgent()
$this->fbeHelper->getPartnerAgent(true)
);
}
}
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"description": "Facebook Business Extension for Magento 2",
"type": "magento2-module",
"license": "GPL-1.0-or-later",
"version": "1.4.4",
"version": "1.4.5",
"require": {
"facebook/php-business-sdk": "9.0.3"
},
Expand Down
2 changes: 1 addition & 1 deletion etc/module.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Module/etc/module.xsd">
<module name="Facebook_BusinessExtension" setup_version="1.4.4">
<module name="Facebook_BusinessExtension" setup_version="1.4.5">
</module>
</config>
1 change: 0 additions & 1 deletion view/frontend/templates/pixel/add_to_cart.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
fbq('set', 'agent', '<?= $block->getFacebookAgentVersion() ?>', '<?= $block->getFacebookPixelID() ?>');
fbq('track', 'AddToCart', {
source: "<?= $block->getSource() ?>",
version: "<?= $block->getMagentoVersion() ?>",
pluginVersion: "<?= $block->getPluginVersion() ?>",
content_type: "<?= $block->getContentType() ?>",
currency: "<?= $block->getCurrency() ?>",
Expand Down
1 change: 0 additions & 1 deletion view/frontend/templates/pixel/head.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ fbq(
);
fbq('track', 'PageView', {
source: "<?= $block->getSource() ?>",
version: "<?= $block->getMagentoVersion() ?>",
pluginVersion: "<?= $block->getPluginVersion() ?>"
});
</script>
Expand Down
1 change: 0 additions & 1 deletion view/frontend/templates/pixel/initiate_checkout.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ if ($block->getFacebookPixelID()) {
fbq('set', 'agent', '<?= $block->getFacebookAgentVersion() ?>', '<?= $block->getFacebookPixelID() ?>');
fbq('track', 'InitiateCheckout', {
source: "<?= $block->getSource() ?>",
version: "<?= $block->getMagentoVersion() ?>",
pluginVersion: "<?= $block->getPluginVersion() ?>",
content_type: "<?= $block->getContentType() ?>",
content_ids: [<?= $block->getContentIDs() ?>],
Expand Down
1 change: 0 additions & 1 deletion view/frontend/templates/pixel/purchase.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ if ($block->getFacebookPixelID()) {
fbq('set', 'agent', '<?= $block->getFacebookAgentVersion() ?>', '<?= $block->getFacebookPixelID() ?>');
fbq('track', 'Purchase', {
source: "<?= $block->getSource() ?>",
version: "<?= $block->getMagentoVersion() ?>",
pluginVersion: "<?= $block->getPluginVersion() ?>",
content_type: "<?= $block->getContentType() ?>",
content_ids: [<?= $block->getContentIDs() ?>],
Expand Down
1 change: 0 additions & 1 deletion view/frontend/templates/pixel/search.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ if ($block->getFacebookPixelID()) {
fbq('set', 'agent', '<?= $block->getFacebookAgentVersion() ?>', '<?= $block->getFacebookPixelID() ?>');
fbq('track', 'Search', {
source: "<?= $block->getSource() ?>",
version: "<?= $block->getMagentoVersion() ?>",
pluginVersion: "<?= $block->getPluginVersion() ?>",
search_string: "<?= $block->getSearchQuery() ?>"
}
Expand Down
1 change: 0 additions & 1 deletion view/frontend/templates/pixel/view_category.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ if ($block->getFacebookPixelID()) {
fbq('set', 'agent', '<?= $block->getFacebookAgentVersion() ?>', '<?= $block->getFacebookPixelID() ?>');
fbq('trackCustom', 'ViewCategory', {
source: "<?= $block->getSource() ?>",
version: "<?= $block->getMagentoVersion() ?>",
pluginVersion: "<?= $block->getPluginVersion() ?>"
<?php if ($block->getCategory()) { ?>
, content_category: "<?= $block->getCategory() ?>"
Expand Down
1 change: 0 additions & 1 deletion view/frontend/templates/pixel/view_content.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ if ($block->getFacebookPixelID()) {
fbq('set', 'agent', '<?= $block->getFacebookAgentVersion() ?>', '<?= $block->getFacebookPixelID() ?>');
fbq('track', 'ViewContent', {
source: "<?= $block->getSource() ?>",
version: "<?= $block->getMagentoVersion() ?>",
pluginVersion: "<?= $block->getPluginVersion() ?>",
content_type: "<?= $block->getContentType() ?>",
content_ids: [<?= $block->getContentIDs() ?>]
Expand Down

0 comments on commit a39db7e

Please sign in to comment.