From 669795d5a4522c6d7826b8f91946d4e4910baf6b Mon Sep 17 00:00:00 2001 From: Fabio Varesano Date: Wed, 28 Jun 2006 18:54:07 +0000 Subject: Patch #70738 by bot (http://drupal.org/user/56659) video_playcounter is never increased fixes the play counter which was no more incremented. --- video.module | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/video.module b/video.module index 5fc7726..c92af7b 100644 --- a/video.module +++ b/video.module @@ -764,6 +764,9 @@ function video_play() { // include video.js file for Internet Explorer fixes theme('video_get_script'); drupal_set_title(t('Playing') . ' ' . theme('placeholder', $node->title)); + if (variable_get('video_playcounter', 1)) { + db_query("UPDATE {video} SET play_counter = play_counter + 1 where vid = %d", $node->vid); //Increment play counter. + } switch (_video_get_filetype($node->vidfile)) { case 'mov': case 'mp4': @@ -790,9 +793,6 @@ function video_play() { drupal_goto("node/$node->nid"); break; } - if (variable_get('video_playcounter', 1)) { - db_query("UPDATE {video} SET play_counter = play_counter + 1 where vid = %d", $node->vid); //Increment play counter. - } } else { drupal_not_found(); -- cgit v1.2.3