Mailer project rwritten:
[mailer.git] / inc / filters.php
index 8c2606b05c9094ed384f4da04f1eb4796716b917..9a4870c3c5c8cef55537d50ea45001247e43ebf1 100644 (file)
@@ -661,6 +661,15 @@ function FILTER_REMOVE_EXTENSION () {
 
 // Filter for flushing the output
 function FILTER_FLUSH_OUTPUT () {
+       // Is this filter called?
+       if (isset($GLOBALS[__FUNCTION__])) {
+               // Abort here
+               reportBug(__FUNCTION__, __LINE__, 'Double call of ' . __FUNCTION__ . ' causes problems with sent headers.');
+       } // END - if
+
+       // Mark this filter as called
+       $GLOBALS[__FUNCTION__] = TRUE;
+
        // Simple, he?
        outputHtml();
 }
@@ -1018,7 +1027,7 @@ function FILTER_FLUSH_TEMPLATE_CACHE () {
 // Filter for loading user data
 function FILTER_FETCH_USER_DATA ($userid = NULL) {
        // Is the userid not set?
-       if (!isValidUserId($userid)) {
+       if (!isValidId($userid)) {
                // Then use member id
                $userid = getMemberId();
        } // END - if