Skip to content

Commit c2810e0

Browse files
Merge pull request #1453 from magento-engcom/develop-prs
[EngCom] Public Pull Requests - MAGETWO-72260: Remove unnecessary comment. #10759 - MAGETWO-72259: phpDocumentor Return tag must be an int #10760 - MAGETWO-72258: Fix minor type "consturctor" > "constructor" #10755 - MAGETWO-72226: Fix for translated attribute label comparisson. #10739 - MAGETWO-71896: Static versioning and styles minification break email fonts styles #8241 #10638
2 parents e05217d + 4271168 commit c2810e0

File tree

9 files changed

+31
-35
lines changed

9 files changed

+31
-35
lines changed

app/code/Magento/Catalog/Block/Product/Compare/ListCompare.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,6 @@ public function getProductAttributeValue($product, $attribute)
206206
['select', 'boolean', 'multiselect']
207207
)
208208
) {
209-
//$value = $attribute->getSource()->getOptionText($product->getData($attribute->getAttributeCode()));
210209
$value = $attribute->getFrontend()->getValue($product);
211210
} else {
212211
$value = $product->getData($attribute->getAttributeCode());

app/code/Magento/Catalog/view/frontend/templates/product/view/attribute.phtml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ if ($_attributeType && $_attributeType == 'text') {
3434

3535
<?php if ($_attributeValue): ?>
3636
<div class="product attribute <?= /* @escapeNotVerified */ $_className ?>">
37-
<?php if ($_attributeLabel != 'none'): ?><strong class="type"><?= /* @escapeNotVerified */ $_attributeLabel ?></strong><?php endif; ?>
37+
<?php if ($_attributeLabel != __('none')): ?><strong class="type"><?= /* @escapeNotVerified */ $_attributeLabel ?></strong><?php endif; ?>
3838
<div class="value" <?= /* @escapeNotVerified */ $_attributeAddAttribute ?>><?= /* @escapeNotVerified */ $_attributeValue ?></div>
3939
</div>
4040
<?php endif; ?>

app/code/Magento/Email/Test/Unit/Model/Template/FilterTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -369,7 +369,7 @@ public function applyInlineCssDataProvider()
369369
'<html><head><style type="text/css">div { color: #111; }</style></head><p></p></html>',
370370
'p { color: #000 }',
371371
[
372-
'<head><style type="text/css">div { color: #111; }</style></head>',
372+
'<style type="text/css">div { color: #111; }</style>',
373373
'<p style="color: #000;"></p>',
374374
],
375375
],

app/code/Magento/Sales/Model/Order.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1774,7 +1774,7 @@ public function getTracksCollection()
17741774
*/
17751775
public function hasInvoices()
17761776
{
1777-
return $this->getInvoiceCollection()->count();
1777+
return (bool)$this->getInvoiceCollection()->count();
17781778
}
17791779

17801780
/**
@@ -1784,7 +1784,7 @@ public function hasInvoices()
17841784
*/
17851785
public function hasShipments()
17861786
{
1787-
return $this->getShipmentsCollection()->count();
1787+
return (bool)$this->getShipmentsCollection()->count();
17881788
}
17891789

17901790
/**
@@ -1794,7 +1794,7 @@ public function hasShipments()
17941794
*/
17951795
public function hasCreditmemos()
17961796
{
1797-
return $this->getCreditmemosCollection()->count();
1797+
return (bool)$this->getCreditmemosCollection()->count();
17981798
}
17991799

18001800
/**

app/code/Magento/Ui/view/base/web/js/lib/core/class.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,12 @@ define([
2727
* Creates constructor function which allows
2828
* initialization without usage of a 'new' operator.
2929
*
30-
* @param {Object} protoProps - Prototypal propeties of a new consturctor.
31-
* @param {Function} consturctor
32-
* @returns {Function} Created consturctor.
30+
* @param {Object} protoProps - Prototypal propeties of a new constructor.
31+
* @param {Function} constructor
32+
* @returns {Function} Created constructor.
3333
*/
34-
function createConstructor(protoProps, consturctor) {
35-
var UiClass = consturctor;
34+
function createConstructor(protoProps, constructor) {
35+
var UiClass = constructor;
3636

3737
if (!UiClass) {
3838

@@ -61,7 +61,7 @@ define([
6161
Class = createConstructor({
6262

6363
/**
64-
* Entry point to the initialization of consturctors' instance.
64+
* Entry point to the initialization of constructor's instance.
6565
*
6666
* @param {Object} [options={}]
6767
* @returns {Class} Chainable.

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
"composer/composer": "1.4.1",
4444
"monolog/monolog": "^1.17",
4545
"oyejorge/less.php": "~1.7.0",
46-
"pelago/emogrifier": "0.1.1",
46+
"pelago/emogrifier": "1.2.0",
4747
"tubalmartin/cssmin": "4.1.0",
4848
"magento/magento-composer-installer": ">=0.1.11",
4949
"braintree/braintree_php": "3.22.0",

composer.lock

Lines changed: 14 additions & 10 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dev/tests/integration/testsuite/Magento/Framework/Css/PreProcessor/Adapter/CssInlinerTest.php

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -75,13 +75,12 @@ public function testGetFilesEmogrifier($htmlFilePath, $cssFilePath, $cssExpected
7575
$emogrifier->setCss($css);
7676
$emogrifier->setHtml($html);
7777
$result = $emogrifier->emogrify();
78+
7879
/**
79-
* Tests a bug in the library where there's no spaces to CSS string before passing to Emogrifier
80-
* to fix known parsing issue with library.
81-
* This test should will fail when this bug is fixed in the library and we should fix the adapter.
82-
* https://github.com/jjriv/emogrifier/issues/370
80+
* This test was implemented for the issue which existed in the older version of Emogrifier.
81+
* Test was updated, as the library got updated as well.
8382
*/
84-
$this->assertNotContains($cssExpected, $result);
83+
$this->assertContains($cssExpected, $result);
8584
}
8685

8786
/**

lib/internal/Magento/Framework/Css/PreProcessor/Adapter/CssInliner.php

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -41,13 +41,7 @@ public function setHtml($html)
4141
*/
4242
public function setCss($css)
4343
{
44-
/**
45-
* Adds space to CSS string before passing to Emogrifier to fix known parsing issue with library.
46-
* https://github.com/jjriv/emogrifier/issues/370
47-
*/
48-
$cssWithAddedSpaces = preg_replace('#([\{\}>])#i', ' $1 ', $css);
49-
50-
$this->emogrifier->setCss($cssWithAddedSpaces);
44+
$this->emogrifier->setCss($css);
5145
}
5246

5347
/**

0 commit comments

Comments
 (0)