Skip to content

Commit

Permalink
Customer Name Prefix shows white space when extra separator is addes. m…
Browse files Browse the repository at this point in the history
  • Loading branch information
ivanbastos committed Sep 16, 2018
1 parent 6c529ec commit 9291068
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions app/code/Magento/Customer/Model/Options.php
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,9 @@ private function prepareNamePrefixSuffixOptions($options, $isOptional = false)
foreach ($options as $value) {
$value = $this->escaper->escapeHtml(trim($value));
$result[$value] = $value;
$result = array_filter($result);
}

if ($isOptional && trim(current($options))) {
$result = array_merge([' ' => ' '], $result);
}
Expand Down

0 comments on commit 9291068

Please sign in to comment.