]> git.mjollnir.org Git - s9y.git/commitdiff
set a source addData tag so that plugins know where the event was pushed
authorgarvinhicking <garvinhicking>
Thu, 25 Aug 2005 12:36:39 +0000 (12:36 +0000)
committergarvinhicking <garvinhicking>
Thu, 25 Aug 2005 12:36:39 +0000 (12:36 +0000)
include/functions_entries.inc.php
include/plugin_internal.inc.php

index 6284b1663d7ac97ae90139f9402ebc071c3a0a04..44e091ed05c83e97ba06ea6558d9cd7f6a1952ca 100644 (file)
@@ -222,7 +222,7 @@ function serendipity_fetchEntries($range = null, $full = true, $limit = '', $fet
         }
     }
 
-    serendipity_plugin_api::hook_event('frontend_fetchentries', $cond, array('noCache' => $noCache, 'noSticky' => $noSticky));
+    serendipity_plugin_api::hook_event('frontend_fetchentries', $cond, array('noCache' => $noCache, 'noSticky' => $noSticky, 'source' => 'entries'));
 
     if ($serendipity['dbType'] == 'postgres') {
         $group    = '';
@@ -482,7 +482,7 @@ function serendipity_searchEntries($term, $limit = '') {
 
     $cond = array();
     $cond['and'] = " AND isdraft = 'false' " . (!serendipity_db_bool($serendipity['showFutureEntries']) ? " AND timestamp <= " . time() : '');
-    serendipity_plugin_api::hook_event('frontend_fetchentries', $cond);
+    serendipity_plugin_api::hook_event('frontend_fetchentries', $cond, array('source' => 'search'));
 
     $serendipity['fullCountQuery'] = "
                       FROM
index d032d4f1b32183f44320a784dcffc30323f705d0..12588aa515a2d9506066c5b4c10a5685f31bc3c5 100644 (file)
@@ -177,7 +177,7 @@ class serendipity_calendar_plugin extends serendipity_plugin {
                                   " . (!serendipity_db_bool($serendipity['showFutureEntries']) ? " AND e.timestamp  <= " . time() : '') . "
                               AND e.isdraft     = 'false'";
 
-        serendipity_plugin_api::hook_event('frontend_fetchentries', $cond, array('noCache' => false, 'noSticky' => false));
+        serendipity_plugin_api::hook_event('frontend_fetchentries', $cond, array('noCache' => false, 'noSticky' => false, 'source' => 'calendar'));
 
         if (isset($serendipity['GET']['category'])) {
             $base_query   = 'C' . (int)$serendipity['GET']['category'];