Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Magento/Core] Fixed typos #382

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion app/code/Magento/Core/Controller/Request/Http.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ class Http extends \Zend_Controller_Request_Http
protected $_controllerModule = null;

/**
* Streight request flag.
* Straight request flag.
* If flag is determined no additional logic is applicable
*
* @var $_isStraight bool
Expand Down
1 change: 0 additions & 1 deletion app/code/Magento/Core/Helper/String.php
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,6 @@ public function splitInjection($str, $length = 50, $needle = '-', $insert = ' ')
foreach ($str as $part) {
if ($this->strlen($part) >= $length) {
$lastDelimetr = $this->strpos($this->strrev($part), $needle);
$tmpNewStr = '';
$tmpNewStr = $this->substr($this->strrev($part), 0, $lastDelimetr)
. $insert . $this->substr($this->strrev($part), $lastDelimetr);
$newStr .= $this->strrev($tmpNewStr);
Expand Down
4 changes: 2 additions & 2 deletions app/code/Magento/Core/Helper/Url.php
Original file line number Diff line number Diff line change
Expand Up @@ -151,8 +151,8 @@ public function addRequestParam($url, $param)
public function removeRequestParam($url, $paramKey, $caseSensitive = false)
{
$regExpression = '/\\?[^#]*?(' . preg_quote($paramKey, '/') . '\\=[^#&]*&?)/' . ($caseSensitive ? '' : 'i');
while (preg_match($regExpression, $url, $mathes) != 0) {
$paramString = $mathes[1];
while (preg_match($regExpression, $url, $matches) != 0) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Always use deep equals!

preg_match() returns 1 if the pattern matches given subject, 0 if it does not, or FALSE if an error occurred.

$paramString = $matches[1];
if (preg_match('/&$/', $paramString) == 0) {
$url = preg_replace('/(&|\\?)?' . preg_quote($paramString, '/') . '/', '', $url);
} else {
Expand Down
4 changes: 2 additions & 2 deletions app/code/Magento/Core/Model/AbstractModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -346,7 +346,7 @@ public function afterLoad()
/**
* Check whether model has changed data.
* Can be overloaded in child classes to perform advanced check whether model needs to be saved
* e.g. usign resouceModel->hasDataChanged() or any other technique
* e.g. using resourceModel->hasDataChanged() or any other technique
*
* @return boolean
*/
Expand Down Expand Up @@ -673,7 +673,7 @@ public function getResource()
}

/**
* Retreive entity id
* Retrieve entity id
*
* @return mixed
*/
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/Core/Model/App/Emulation.php
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ public function startEnvironmentEmulation($storeId, $area = \Magento\Core\Model\
}

/**
* Stop enviromment emulation
* Stop environment emulation
*
* Function restores initial store environment
*
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/Core/Model/Cache.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@

/**
* System cache model
* support id and tags preffix support,
* support id and tags prefix support,
*/

namespace Magento\Core\Model;
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/Core/Model/Cookie.php
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,7 @@ public function renew($name, $period = null, $path = null, $domain = null, $secu
/**
* Retrieve cookie or false if not exists
*
* @param string $neme The cookie name
* @param string $name The cookie name
* @return mixed
*/
public function get($name = null)
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/Core/Model/Dir.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* Application file system directories dictionary
*
* Provides information about what directories are available in the application
* Serves as customizaiton point to specify different directories or add own
* Serves as customization point to specify different directories or add own
*
* Magento
*
Expand Down
4 changes: 2 additions & 2 deletions app/code/Magento/Core/Model/Email/Template/Mailer.php
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ public function send()
// Send all emails from corresponding list
while (!empty($this->_emailInfos)) {
$emailInfo = array_pop($this->_emailInfos);
// Handle "Bcc" recepients of the current email
// Handle "Bcc" recipients of the current email
$emailTemplate->addBcc($emailInfo->getBccEmails());
// Set required design parameters and delegate email sending to \Magento\Core\Model\Email\Template
$designConfig = array(
Expand Down Expand Up @@ -172,7 +172,7 @@ public function getTemplateId()
}

/**
* Set tempate parameters
* Set template parameters
*
* @param array $templateParams
* @return \Magento\Core\Model\Email\Template\Mailer
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/Core/Model/File/Storage.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class Storage extends \Magento\Core\Model\AbstractModel
const STORAGE_MEDIA_DATABASE = 1;

/**
* Config pathes for storing storage configuration
* Config paths for storing storage configuration
*/
const XML_PATH_STORAGE_MEDIA = 'system/media_storage_configuration/media_storage';
const XML_PATH_STORAGE_MEDIA_DATABASE = 'system/media_storage_configuration/media_database';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ public function getSubdirectories($directory)
/**
* Delete directory from database
*
* @param string $path
* @param string $dirPath
* @return \Magento\Core\Model\File\Storage\Directory\Database
*/
public function deleteDirectory($dirPath)
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/Core/Model/Image/AdapterFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ public function __construct(
* @param string $adapterType
* @return \Magento\Image\Adapter\AbstractAdapter
* @throws \InvalidArgumentException
* @throws \Exception if some of dependecies are missing
* @throws \Exception if some of dependencies are missing
*/
public function create($adapterType = null)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ protected function _getArgumentValue(\Magento\Core\Model\Layout\Element $argumen
}

/**
* Check whether updater used and value not overwriten
* Check whether updater used and value not overwritten
*
* @param \Magento\Core\Model\Layout\Element $argument
* @return string
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ protected function _validate(array $argument)
}

/**
* Retrive value from Array argument
* Retrieve value from Array argument
*
* @param \Magento\Core\Model\Layout\Element $argument
* @return array|null
Expand Down
6 changes: 3 additions & 3 deletions app/code/Magento/Core/Model/Locale.php
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ public function setDefaultLocale($locale)
}

/**
* REtrieve default locale code
* Retrieve default locale code
*
* @return string
*/
Expand Down Expand Up @@ -241,7 +241,7 @@ public function setLocaleCode($code)
}

/**
* Get options array for locale dropdown in currunt locale
* Get options array for locale dropdown in current locale
*
* @return array
*/
Expand Down Expand Up @@ -557,7 +557,7 @@ public function utcDate($store, $date, $includeTime = false, $format = null)

/**
* Get store timestamp
* Timstamp will be builded with store timezone settings
* Timestamp will be built with store timezone settings
*
* @param mixed $store
* @return int
Expand Down
6 changes: 3 additions & 3 deletions app/code/Magento/Core/Model/LocaleInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ interface LocaleInterface
public function setDefaultLocale($locale);

/**
* REtrieve default locale code
* Retrieve default locale code
*
* @return string
*/
Expand Down Expand Up @@ -117,7 +117,7 @@ public function getLocaleCode();
public function setLocaleCode($code);

/**
* Get options array for locale dropdown in currunt locale
* Get options array for locale dropdown in current locale
*
* @return array
*/
Expand Down Expand Up @@ -246,7 +246,7 @@ public function utcDate($store, $date, $includeTime = false, $format = null);

/**
* Get store timestamp
* Timstamp will be builded with store timezone settings
* Timestamp will be built with store timezone settings
*
* @param mixed $store
* @return int
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ public function createPluginDefinition()
}

/**
* Retreive class relations list
* Retrieve class relations list
*
* @return \Magento\Core\Model\ObjectManager\Relations|\Magento\ObjectManager\Relations\Runtime
*/
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/Core/Model/Resource/Config/Data.php
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ public function clearWebsiteData(\Magento\Core\Model\Website $website)
}

/**
* Cleare store data
* Clear store data
*
* @param array $storeIds
*/
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/Core/Model/Resource/Db/AbstractDb.php
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ abstract class AbstractDb extends \Magento\Core\Model\Resource\AbstractResource
protected $_idFieldName;

/**
* Primery key auto increment flag
* Primary key auto increment flag
*
* @var bool
*/
Expand Down
8 changes: 4 additions & 4 deletions app/code/Magento/Core/Model/Resource/Email/Template.php
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ protected function _beforeSave(\Magento\Core\Model\AbstractModel $object)
}

/**
* Retrieve config scope and scope id of specified email template by email pathes
* Retrieve config scope and scope id of specified email template by email paths
*
* @param array $paths
* @param int|string $templateId
Expand All @@ -121,13 +121,13 @@ protected function _beforeSave(\Magento\Core\Model\AbstractModel $object)
public function getSystemConfigByPathsAndTemplateId($paths, $templateId)
{
$orWhere = array();
$pathesCounter = 1;
$pathsCounter = 1;
$bind = array();
foreach ($paths as $path) {
$pathAlias = 'path_' . $pathesCounter;
$pathAlias = 'path_' . $pathsCounter;
$orWhere[] = 'path = :' . $pathAlias;
$bind[$pathAlias] = $path;
$pathesCounter++;
$pathsCounter++;
}
$bind['template_id'] = $templateId;
$select = $this->_getReadAdapter()->select()
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/Core/Model/Resource/Setup.php
Original file line number Diff line number Diff line change
Expand Up @@ -791,7 +791,7 @@ public function getCallAfterApplyAllUpdates()

/**
* Run each time after applying of all updates,
* if setup model setted $_callAfterApplyAllUpdates flag to true
* if setup model setted $_callAfterApplyAllUpdates flag to true
*
* @return \Magento\Core\Model\Resource\Setup
*/
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/Core/Model/Resource/Transaction.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
/**
* Resource transaction model
*
* @todo need collect conection by name
* @todo need collect connection by name
* @category Magento
* @package Magento_Core
* @author Magento Core Team <core@magentocommerce.com>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@


/**
* Custom variabel collection
* Custom variable collection
*
* @category Magento
* @package Magento_Core
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/Core/Model/Store/Group.php
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ public function getStoreCollection()
}

/**
* Retrieve wersite store objects
* Retrieve website store objects
*
* @return array
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ public function __construct(
}

/**
* Initialize current applicaition store
* Initialize current application store
*/
public function initCurrentStore()
{
Expand Down
4 changes: 2 additions & 2 deletions app/code/Magento/Core/Model/Template.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,15 +48,15 @@ abstract class Template extends \Magento\Core\Model\AbstractModel
const DEFAULT_DESIGN_AREA = 'frontend';

/**
* Configuration of desing package for template
* Configuration of design package for template
*
* @var \Magento\Object
*/
protected $_designConfig;


/**
* Configuration of emulated desing package.
* Configuration of emulated design package.
*
* @var \Magento\Object|boolean
*/
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/Core/Model/Website.php
Original file line number Diff line number Diff line change
Expand Up @@ -422,7 +422,7 @@ public function getStoreCollection()
}

/**
* Retrieve wersite store objects
* Retrieve website store objects
*
* @return array
*/
Expand Down
4 changes: 2 additions & 2 deletions app/code/Magento/Core/i18n/fr_FR.csv
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"Advanced","Avancé(e)"
"After selecting a new media storage location, press the Synchronize button
to transfer all media to that location. Media will not be available in the new
location until the synchronization process is complete.","Après avoir sélectionn un nouveau lieu de stockage des médias, appuyez sur le bouton Synchroniser pour transférer tous les médias vers cet emplacement. Les médias ne seront disponibles dans le nouvel emplacement que lorsque la processus sera terminé."
location until the synchronization process is complete.","Après avoir sélectionné un nouveau lieu de stockage des médias, appuyez sur le bouton Synchroniser pour transférer tous les médias vers cet emplacement. Les médias ne seront disponibles dans le nouvel emplacement que lorsque la processus sera terminé."
"Allow Countries","Permettre pays"
"Allow Symlinks","Autoriser les Symlinks"
"Allowed IPs (comma separated)","IPs permis (séparés par virgule)"
Expand All @@ -24,7 +24,7 @@
"An error occurred while saving. Please review the error log.","Une erreur est survenue durant sauvegarde. Veuillez consulter le journal de bord des erreurs."
"Anchor Text for Next","Ancrer texte pour suivant"
"Anchor Text for Previous","Ancrer texte pour précédent"
"Anchor symbol (#) is not supported in request path","Le symbolr d'ancrage (#) n'est pas pris en charge dans la demande de chemin d'accès"
"Anchor symbol (#) is not supported in request path","Le symbole d'ancrage (#) n'est pas pris en charge dans la demande de chemin d'accès"
"Anchor symbol (#) is not supported in url rewrite suffix","Le symbole d'ancrage (#) n'est pas pris en charge dans le suffixe de réécriture de l'url"
"Are you sure?","Etes-vous sûr ?"
"Auto-redirect to Base URL","Redirige automatiquement vers base URL"
Expand Down