Skip to content

Commit 433e9e7

Browse files
committed
Fixing typos in time helper translations
1 parent b68bc7d commit 433e9e7

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

lib/Cake/View/Helper/TimeHelper.php

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -82,19 +82,19 @@ public function convertSpecifiers($format, $time = null) {
8282
private function __translateSpecifier($specifier) {
8383
switch ($specifier[1]) {
8484
case 'a':
85-
$abday = __cn('cake', 'abday', 5);
85+
$abday = __dc('cake', 'abday', 5);
8686
if (is_array($abday)) {
8787
return $abday[date('w', $this->__time)];
8888
}
8989
break;
9090
case 'A':
91-
$day = __cn('cake', 'day', 5);
91+
$day = __dc('cake', 'day', 5);
9292
if (is_array($day)) {
9393
return $day[date('w', $this->__time)];
9494
}
9595
break;
9696
case 'c':
97-
$format = __cn('cake', 'd_t_fmt', 5);
97+
$format = __dc('cake', 'd_t_fmt', 5);
9898
if ($format != 'd_t_fmt') {
9999
return $this->convertSpecifiers($format, $this->__time);
100100
}
@@ -116,13 +116,13 @@ private function __translateSpecifier($specifier) {
116116
return date('jS', $this->__time);
117117
case 'b':
118118
case 'h':
119-
$months = __cn('cake', 'abmon', 5);
119+
$months = __dc('cake', 'abmon', 5);
120120
if (is_array($months)) {
121121
return $months[date('n', $this->__time) -1];
122122
}
123123
return '%b';
124124
case 'B':
125-
$months = __cn('cake', 'mon', 5);
125+
$months = __dc('cake', 'mon', 5);
126126
if (is_array($months)) {
127127
return $months[date('n', $this->__time) -1];
128128
}
@@ -133,14 +133,14 @@ private function __translateSpecifier($specifier) {
133133
case 'P':
134134
$default = array('am' => 0, 'pm' => 1);
135135
$meridiem = $default[date('a',$this->__time)];
136-
$format = __cn('cake', 'am_pm', 5);
136+
$format = __dc('cake', 'am_pm', 5);
137137
if (is_array($format)) {
138138
$meridiem = $format[$meridiem];
139139
return ($specifier[1] == 'P') ? strtolower($meridiem) : strtoupper($meridiem);
140140
}
141141
break;
142142
case 'r':
143-
$complete = __cn('cake', 't_fmt_ampm', 5);
143+
$complete = __dc('cake', 't_fmt_ampm', 5);
144144
if ($complete != 't_fmt_ampm') {
145145
return str_replace('%p',$this->__translateSpecifier(array('%p', 'p')),$complete);
146146
}
@@ -154,13 +154,13 @@ private function __translateSpecifier($specifier) {
154154
case 'u':
155155
return ($weekDay = date('w', $this->__time)) ? $weekDay : 7;
156156
case 'x':
157-
$format = __cn('cake', 'd_fmt', 5);
157+
$format = __dc('cake', 'd_fmt', 5);
158158
if ($format != 'd_fmt') {
159159
return $this->convertSpecifiers($format, $this->__time);
160160
}
161161
break;
162162
case 'X':
163-
$format = __cn('cake', 't_fmt', 5);
163+
$format = __dc('cake', 't_fmt', 5);
164164
if ($format != 't_fmt') {
165165
return $this->convertSpecifiers($format, $this->__time);
166166
}

0 commit comments

Comments
 (0)