r86358 MediaWiki - Code Review archive
Repository:
MediaWiki
Revision:
<
r86357
|
r86358
|
r86359
>
Date:
22:42, 18 April 2011
Author:
jeroendedauw
Status:
deferred
Tags:
Comment:
fixed obvious devision by zero issue
Modified paths:
/trunk/extensions/Ratings/Ratings.class.php
(modified) (
history
)
Diff
[
purge
]
Index: trunk/extensions/Ratings/Ratings.class.php
—
—
@@ -131,7 +131,7 @@
132
132
}
133
133
134
134
foreach ( $tags as &$tag ) {
135
- $tag['avarage'] = $tag['total'] / $tag['count'];
135
+ $tag['avarage'] = $tag['count'] > 0 ? $tag['total'] / $tag['count'] : 0;
136
136
}
137
137
138
138
return $tags;
Status & tagging log
23:47, 18 April 2011
Reedy
(
talk
|
contribs
)
changed the
status
of r86358
[
removed:
new
added:
deferred]