diff options
author | rvelices <rv-github@modusoptimus.com> | 2014-02-09 20:46:06 +0000 |
---|---|---|
committer | rvelices <rv-github@modusoptimus.com> | 2014-02-09 20:46:06 +0000 |
commit | a1e0f1b52f1ef6bd6c68835748d9259cddff5e0d (patch) | |
tree | 3dea7d5323cc779581fb112f32b106d4705d90e0 /include | |
parent | 57dc064a18b078d69e37def1f54a27b234ee10a3 (diff) |
feature 3043: Add event to allow calculation of rating score with a different algorithm
git-svn-id: http://piwigo.org/svn/trunk@27294 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to '')
-rw-r--r-- | include/functions_rate.inc.php | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/functions_rate.inc.php b/include/functions_rate.inc.php index 2644caad9..ae896c29a 100644 --- a/include/functions_rate.inc.php +++ b/include/functions_rate.inc.php @@ -136,6 +136,11 @@ INSERT */ function update_rating_score($element_id = false) { + if ( ($alt_result = trigger_event('update_rating_score', false, $element_id)) !== false) + { + return $alt_result; + } + $query = ' SELECT element_id, COUNT(rate) AS rcount, |