Skip to content

Commit

Permalink
CORE-763 Implement recommendations from peer review
Browse files Browse the repository at this point in the history
  • Loading branch information
Thomas Kühnel committed Jun 16, 2017
1 parent 5a7518f commit 069b0f2
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ class LocaleDataHelper extends Module

use LocatorHelperTrait;

const LOCALE_NAME_LENGTH_LIMIT = 5;

/**
* @param array $seedData
*
Expand Down Expand Up @@ -49,7 +51,7 @@ protected function generateLocaleTransfer(array $seedData = [])
{
$localeTransfer = (new LocaleBuilder($seedData))->build();

if (strlen($localeTransfer->getLocaleName()) > 5) {
if (strlen($localeTransfer->getLocaleName()) > static::LOCALE_NAME_LENGTH_LIMIT) {
return $this->generateLocaleTransfer($seedData);
}

Expand Down

0 comments on commit 069b0f2

Please sign in to comment.