Skip to content
This repository was archived by the owner on Feb 8, 2023. It is now read-only.

Commit f0aeb4d

Browse files
Merge pull request #12 from mageplaza/2.4-develop
2.4 develop
2 parents d532339 + 9ed4dda commit f0aeb4d

File tree

5 files changed

+57
-55
lines changed

5 files changed

+57
-55
lines changed

Block/Sitemap.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,9 @@ public function getProductCollection()
141141
->addTaxPercents()
142142
->setPageSize($limit)
143143
->addAttributeToSelect('*');
144-
$this->_stockFilter->addInStockFilterToCollection($collection);
144+
if (!$this->_helper->getConfigValue('cataloginventory/options/show_out_of_stock')) {
145+
$this->_stockFilter->addInStockFilterToCollection($collection);
146+
}
145147

146148
return $collection;
147149
}

Model/Sitemap.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -411,7 +411,7 @@ public function _getProductCollection($storeId)
411411
*/
412412
public function convertUrl($url)
413413
{
414-
if (preg_match(self::PATTERN, $url)) {
414+
if (preg_match('@^http://@i', $url) || preg_match('@^https://@i', $url)) {
415415
return $url;
416416
}
417417

composer.json

Lines changed: 27 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,27 @@
1-
{
2-
"name": "mageplaza/module-sitemap",
3-
"description": "Magento 2 Google XML Sitemap extension",
4-
"require": {
5-
"mageplaza/module-core": "^1.4.5",
6-
"mageplaza/magento-2-seo-extension": "^2.1.0"
7-
},
8-
"type": "magento2-module",
9-
"version": "1.0.3",
10-
"license": "proprietary",
11-
"authors": [
12-
{
13-
"name": "Mageplaza",
14-
"email": "support@mageplaza.com",
15-
"homepage": "https://www.mageplaza.com",
16-
"role": "Technical Support"
17-
}
18-
],
19-
"autoload": {
20-
"files": [
21-
"registration.php"
22-
],
23-
"psr-4": {
24-
"Mageplaza\\Sitemap\\": ""
25-
}
26-
}
27-
}
1+
{
2+
"name": "mageplaza/module-sitemap",
3+
"description": "Magento 2 Google XML Sitemap extension",
4+
"require": {
5+
"mageplaza/module-core": "^1.4.5",
6+
"mageplaza/magento-2-seo-extension": "^4.0.0"
7+
},
8+
"type": "magento2-module",
9+
"version": "4.0.0",
10+
"license": "proprietary",
11+
"authors": [
12+
{
13+
"name": "Mageplaza",
14+
"email": "support@mageplaza.com",
15+
"homepage": "https://www.mageplaza.com",
16+
"role": "Technical Support"
17+
}
18+
],
19+
"autoload": {
20+
"files": [
21+
"registration.php"
22+
],
23+
"psr-4": {
24+
"Mageplaza\\Sitemap\\": ""
25+
}
26+
}
27+
}

i18n/en_US.csv

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,25 @@
1-
"Parameter is incorrect.","Parameter is incorrect."
2-
"HTML Sitemap","HTML Sitemap"
3-
"Enable HTML Sitemap","Enable HTML Sitemap"
4-
"Enable Categories Sitemap","Enable Categories Sitemap"
5-
"Enable Products Sitemap","Enable Products Sitemap"
6-
"Limit Product Sitemap","Limit Product Sitemap"
7-
"Default is 100","Default is 100"
8-
"Enable Pages Sitemap","Enable Pages Sitemap"
9-
"Enable Exclude Pages Sitemap","Enable Exclude Pages Sitemap"
10-
"Filter Cms Pages","Filter Cms Pages"
11-
"Enable Additional Links","Enable Additional Links"
12-
"Additional Links","Additional Links"
13-
"Add Sitemap Link to Footer","Add Sitemap Link to Footer"
14-
"XML Sitemap","XML Sitemap"
15-
"Homepage Optimization","Homepage Optimization"
16-
"In sitemap file, it will remove the link of the CMS page using for homepage.","In sitemap file, it will remove the link of the CMS page using for homepage."
17-
"Yes, if you want to add more custom links into sitemap XML file.","Yes, if you want to add more custom links into sitemap XML file."
18-
"One link per line.","One link per line."
19-
Frequency,Frequency
20-
"One of the following value: <i>always, hourly, daily, weekly, monthly, yearly, never</i>. <a href=""https://www.sitemaps.org/protocol.html"" target=""_blank"">Learn more.</a>","One of the following value: <i>always, hourly, daily, weekly, monthly, yearly, never</i>. <a href=""https://www.sitemaps.org/protocol.html"" target=""_blank"">Learn more.</a>"
21-
Priority,Priority
22-
"From 0 to 1. E.g: 0.5 or 0.8","From 0 to 1. E.g: 0.5 or 0.8"
23-
"Exclude Sitemap","Exclude Sitemap"
24-
"Added by Mageplaza Sitemap","Added by Mageplaza Sitemap"
25-
Sitemap,Sitemap
1+
"Parameter is incorrect.","Parameter is incorrect."
2+
"HTML Sitemap","HTML Sitemap"
3+
"Enable HTML Sitemap","Enable HTML Sitemap"
4+
"Enable Categories Sitemap","Enable Categories Sitemap"
5+
"Enable Products Sitemap","Enable Products Sitemap"
6+
"Limit Product Sitemap","Limit Product Sitemap"
7+
"Default is 100","Default is 100"
8+
"Enable Pages Sitemap","Enable Pages Sitemap"
9+
"Enable Exclude Pages Sitemap","Enable Exclude Pages Sitemap"
10+
"Filter Cms Pages","Filter Cms Pages"
11+
"Enable Additional Links","Enable Additional Links"
12+
"Additional Links","Additional Links"
13+
"Add Sitemap Link to Footer","Add Sitemap Link to Footer"
14+
"XML Sitemap","XML Sitemap"
15+
"Homepage Optimization","Homepage Optimization"
16+
"In sitemap file, it will remove the link of the CMS page using for homepage.","In sitemap file, it will remove the link of the CMS page using for homepage."
17+
"Yes, if you want to add more custom links into sitemap XML file.","Yes, if you want to add more custom links into sitemap XML file."
18+
"One link per line.","One link per line."
19+
Frequency,Frequency
20+
"One of the following value: <i>always, hourly, daily, weekly, monthly, yearly, never</i>. <a href=""https://www.sitemaps.org/protocol.html"" target=""_blank"">Learn more.</a>","One of the following value: <i>always, hourly, daily, weekly, monthly, yearly, never</i>. <a href=""https://www.sitemaps.org/protocol.html"" target=""_blank"">Learn more.</a>"
21+
Priority,Priority
22+
"From 0 to 1. E.g: 0.5 or 0.8","From 0 to 1. E.g: 0.5 or 0.8"
23+
"Exclude Sitemap","Exclude Sitemap"
24+
"Added by Mageplaza Sitemap","Added by Mageplaza Sitemap"
25+
Sitemap,Sitemap

view/frontend/templates/disablelink.phtml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121

2222
/** @var \Mageplaza\Sitemap\Block\Sitemap $block */
2323
?>
24-
<?php if (!$block->isEnableHtmlSitemap()) : ?>
24+
<?php if (!$block->isEnableHtmlSitemap()): ?>
2525
<style type="text/css">
2626
.footer.links a[href*="sitemap"] {
2727
display: none;

0 commit comments

Comments
 (0)