Skip to content

Commit 7ef4729

Browse files
author
Karpenko, Oleksandr
committed
MAGETWO-57656: Base url should be processed while sending email
1 parent 7592059 commit 7ef4729

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

app/code/Magento/Email/Model/Template/Filter.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -928,7 +928,7 @@ public function getCssFilesContent(array $files)
928928
try {
929929
foreach ($files as $file) {
930930
$asset = $this->_assetRepo->createAsset($file, $designParams);
931-
$filePath = $asset->getContext()->getPath() . '/' . $file;
931+
$filePath = $asset->getContext()->getPath() . DIRECTORY_SEPARATOR . $file;
932932
if ($this->getPubDirectory()->isExist($filePath)) {
933933
$css .= $this->getPubDirectory()->readFile($filePath);
934934
} else {

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -320,11 +320,11 @@ public function testGetCssFilesContent()
320320
$reflectionProperty->setValue($filter, $pubDirectory);
321321
$pubDirectory->expects($this->once())
322322
->method('isExist')
323-
->with($path . '/' . $file)
323+
->with($path . DIRECTORY_SEPARATOR . $file)
324324
->willReturn(true);
325325
$pubDirectory->expects($this->once())
326326
->method('readFile')
327-
->with($path . '/' . $file)
327+
->with($path . DIRECTORY_SEPARATOR . $file)
328328
->willReturn($css);
329329

330330
$filter->setDesignParams($designParams);

0 commit comments

Comments
 (0)