cvs: pear /Date Date.php /Date/Date Calc.php
| From: | Charles Woodcock | Date: | Sat, 08 Dec 2007 19:59:39 +0000 |
| Subject: | cvs: pear /Date Date.php /Date/Date Calc.php | ||
| Groups: | php.pear.cvs | ||
| Request: | Send a blank email to pear-cvs+get-49670@lists.php.net to get a copy of this message | ||
c01234 Sat Dec 8 19:59:39 2007 UTC
Modified files:
/pear/Date Date.php
/pear/Date/Date Calc.php
Log:
coding standards
http://cvs.php.net/viewvc.cgi/pear/Date/Date.php?r1=1.86&r2=1.87&diff_format=u
Index: pear/Date/Date.php
diff -u pear/Date/Date.php:1.86 pear/Date/Date.php:1.87
--- pear/Date/Date.php:1.86 Sun Dec 2 14:00:02 2007
+++ pear/Date/Date.php Sat Dec 8 19:59:39 2007
@@ -43,7 +43,7 @@
* @copyright 1997-2007 Baba Buehler, Pierre-Alain Joye, Firman Wandayandi, C.A. Woodcock
* @license http://www.opensource.org/licenses/bsd-license.php
* BSD License
- * @version CVS: $Id: Date.php,v 1.86 2007/12/02 14:00:02 c01234 Exp $
+ * @version CVS: $Id: Date.php,v 1.87 2007/12/08 19:59:39 c01234 Exp $
* @link http://pear.php.net/package/Date
*/
@@ -2464,12 +2464,12 @@
$i += 5;
} else if (strtoupper(substr($ps_format, $i, 3)) == "MON") {
$hs_month = Date_Calc::getMonthAbbrname($this->month);
- $ret .= $hb_lower ?
- strtolower($hs_month) :
- (substr($ps_format, $i + 1, 1) == "O" ?
- strtoupper($hs_month) :
- $hs_month);
- $i += 3;
+ $ret .= $hb_lower ?
+ strtolower($hs_month) :
+ (substr($ps_format, $i + 1, 1) == "O" ?
+ strtoupper($hs_month) :
+ $hs_month);
+ $i += 3;
}
break;
@@ -2736,7 +2736,7 @@
case "U":
if ($this->ob_invalidtime)
return $this->_getErrorInvalidTime();
- $hn_unixtime = $this->getTime();
+ $hn_unixtime = $this->getTime();
$hs_numberformat = substr($ps_format, $i + 1, 4);
// Allow sign if negative; allow all digits (specify nought);
@@ -2924,7 +2924,7 @@
1)) == "Y")
++$hn_codelen;
- $hs_thousandsep = null;
+ $hs_thousandsep = null;
$hn_thousandseps = 0;
if ($hn_codelen <= 3) {
while (preg_match('/([,.·\' ])YYY/i',
@@ -2932,7 +2932,7 @@
$i + $hn_codelen,
4),
$ha_matches)) {
- $hn_codelen += 4;
+ $hn_codelen += 4;
$hs_thousandsep = $ha_matches[1];
++$hn_thousandseps;
}
http://cvs.php.net/viewvc.cgi/pear/Date/Date/Calc.php?r1=1.55&r2=1.56&diff_format=u
Index: pear/Date/Date/Calc.php
diff -u pear/Date/Date/Calc.php:1.55 pear/Date/Date/Calc.php:1.56
--- pear/Date/Date/Calc.php:1.55 Thu Nov 29 20:54:22 2007
+++ pear/Date/Date/Calc.php Sat Dec 8 19:59:39 2007
@@ -42,7 +42,7 @@
* @copyright 1999-2007 Monte Ohrt, Pierre-Alain Joye, Daniel Convissor, C.A. Woodcock
* @license http://www.opensource.org/licenses/bsd-license.php
* BSD License
- * @version CVS: $Id: Calc.php,v 1.55 2007/11/29 20:54:22 c01234 Exp $
+ * @version CVS: $Id: Calc.php,v 1.56 2007/12/08 19:59:39 c01234 Exp $
* @link http://pear.php.net/package/Date
* @since File available since Release 1.2
*/
@@ -419,7 +419,7 @@
function getSecondsInMonth($pn_month, $pn_year)
{
$pn_month = intval($pn_month);
- $pn_year = intval($pn_year);
+ $pn_year = intval($pn_year);
static $ha_leapseconds;
if (!isset($ha_leapseconds)) {
@@ -494,9 +494,9 @@
// second (I do not know what they are called), or a number of
// consecutive leap seconds).
- $pn_day = intval($pn_day);
+ $pn_day = intval($pn_day);
$pn_month = intval($pn_month);
- $pn_year = intval($pn_year);
+ $pn_year = intval($pn_year);
static $ha_leapseconds;
if (!isset($ha_leapseconds)) {
@@ -1999,7 +1999,9 @@
$hn_wd1 = Date_Calc::daysToDayOfWeek(Date_Calc::firstDayOfYear($pn_year));
$hn_day = Date_Calc::dayOfYear($pn_day, $pn_month, $pn_year);
- $hn_week = floor(($hn_day + (10 + $hn_wd1 - $pn_firstdayofweek) % 7 + 3) / 7);
+ $hn_week = floor(($hn_day +
+ (10 + $hn_wd1 - $pn_firstdayofweek) % 7 +
+ 3) / 7);
if ($hn_week > 0) {
$hn_year = $pn_year;
@@ -4156,9 +4158,9 @@
$hn_second = 0;
$hn_firstofmonth = Date_Calc::firstDayOfMonth($pn_month, $pn_year);
- $hn_midmonth = (Date_Calc::lastDayOfMonth($pn_month, $pn_year) +
- 1 -
- $hn_firstofmonth) / 2;
+ $hn_midmonth = (Date_Calc::lastDayOfMonth($pn_month, $pn_year) +
+ 1 -
+ $hn_firstofmonth) / 2;
if (($hn_days = Date_Calc::dateToDays($pn_day,
$pn_month,
$pn_year) -