Skip to content
This repository has been archived by the owner on Nov 3, 2023. It is now read-only.

Commit

Permalink
Merge branch 'hotfix/3.4.2'
Browse files Browse the repository at this point in the history
  • Loading branch information
leofeyer committed Jan 22, 2015
2 parents 960155b + e71f240 commit b7d0a7e
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 13 deletions.
2 changes: 1 addition & 1 deletion system/config/constants.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
* Core version
*/
define('VERSION', '3.4');
define('BUILD', '1');
define('BUILD', '2');
define('LONG_TERM_SUPPORT', false);


Expand Down
7 changes: 7 additions & 0 deletions system/docs/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
Contao Open Source CMS changelog
================================

Version 3.4.2 (2015-01-22)
--------------------------

### Fixed
Fix an infinite recursion problem in the `FilesModel` class (see #7588).


Version 3.4.1 (2015-01-22)
--------------------------

Expand Down
20 changes: 8 additions & 12 deletions system/modules/core/library/Contao/Model.php
Original file line number Diff line number Diff line change
Expand Up @@ -780,23 +780,19 @@ public static function findMultipleByIds($arrIds, array $arrOptions=array())
*/
public static function findOneBy($strColumn, $varValue, array $arrOptions=array())
{
$intId = is_array($varValue) ? $varValue[0] : $varValue;

// Try to load from the registry
if (empty($arrOptions))
{
if (is_array($strColumn))
{
if (count($strColumn) == 1 && $strColumn[0] == static::$strPk)
{
return static::findByPk($intId, $arrOptions);
}
}
else
$arrColumn = (array) $strColumn;

if (count($arrColumn) == 1 && $arrColumn[0] == static::$strPk)
{
if ($strColumn == static::$strPk)
$intId = is_array($varValue) ? $varValue[0] : $varValue;
$objModel = \Model\Registry::getInstance()->fetch(static::$strTable, $intId);

if ($objModel !== null)
{
return static::findByPk($intId, $arrOptions);
return $objModel;
}
}
}
Expand Down
1 change: 1 addition & 0 deletions system/modules/repository/classes/RepositorySettings.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@

// valid core versions in descending order
define('REPOSITORY_COREVERSIONS',
'30040029,30040029;'. // 3.4.2
'30040019,30040019;'. // 3.4.1
'30040009,30040009;'. // 3.4.0
'30040006,30040006;'. // 3.4.0-RC1
Expand Down

0 comments on commit b7d0a7e

Please sign in to comment.