Skip to content

Commit dcdf45d

Browse files
committed
changes from feedback
1 parent 81633ab commit dcdf45d

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

ext/calendar/dow.c

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -33,14 +33,7 @@
3333
int DayOfWeek(
3434
zend_long sdn)
3535
{
36-
int dow;
37-
38-
dow = (int)(sdn % 7 + 1);
39-
if (dow >= 0) {
40-
return (dow % 7);
41-
} else {
42-
return (dow + 7) % 7;
43-
}
36+
return (int)(sdn % 7 + 8) % 7;
4437
}
4538

4639
const char * const DayNameShort[7] =

0 commit comments

Comments
 (0)