[Svn-src-all:2747] [version-2_12-dev 21646] #1679 (PHP 警告撲滅)
Seasoft
admin @ mail.ec-cube.net
2012年 3月 14日 (水) 21:34:50 JST
Subversion committed to /home/svn/open 21646
http://svn.ec-cube.net/open_trac/changeset/21646
┌────────────────────────────┐
│更新者 : Seasoft │
│更新日時: 2012-03-14 21:34:50 +0900 (水, 14 3月 2012)│
└────────────────────────────┘
Log:
--------------------------------------------------------
#1679 (PHP 警告撲滅)
Changed: [U:修正,A:追加,D:削除]
--------------------------------------------------------
U branches/version-2_12-dev/data/class/SC_Product.php
U branches/version-2_12-dev/data/class/util/SC_Utils.php
変更: branches/version-2_12-dev/data/class/SC_Product.php
===================================================================
--- branches/version-2_12-dev/data/class/SC_Product.php 2012-03-14 05:37:35 UTC (rev 21645)
+++ branches/version-2_12-dev/data/class/SC_Product.php 2012-03-14 12:34:50 UTC (rev 21646)
@@ -207,10 +207,10 @@
*/
function getDetail($productId) {
$objQuery =& SC_Query_Ex::getSingletonInstance();
- $result = $objQuery->select('*', $this->alldtlSQL('product_id = ?'),
+ $result = $objQuery->getRow('*', $this->alldtlSQL('product_id = ?'),
'product_id = ?',
array($productId, $productId));
- return $result[0];
+ return (array)$result;
}
/**
@@ -394,7 +394,7 @@
$objQuery =& SC_Query_Ex::getSingletonInstance();
$objQuery->setWhere('product_class_id = ? AND T1.del_flg = 0');
$arrRes = $this->getProductsClassByQuery($objQuery, $productClassId);
- return $arrRes[0];
+ return (array)$arrRes[0];
}
/**
変更: branches/version-2_12-dev/data/class/util/SC_Utils.php
===================================================================
--- branches/version-2_12-dev/data/class/util/SC_Utils.php 2012-03-14 05:37:35 UTC (rev 21645)
+++ branches/version-2_12-dev/data/class/util/SC_Utils.php 2012-03-14 12:34:50 UTC (rev 21646)
@@ -737,6 +737,7 @@
function sfSwapArray($array, $isColumnName = true) {
$arrRet = array();
foreach ($array as $key1 => $arr1) {
+ if (!is_array($arr1)) break 1;
$index = 0;
foreach ($arr1 as $key2 => $val) {
if ($isColumnName) {
Svn-src-all メーリングリストの案内