Index: trunk/phase3/includes/GlobalFunctions.php |
— | — | @@ -3053,6 +3053,16 @@ |
3054 | 3054 | } |
3055 | 3055 | } |
3056 | 3056 | |
| 3057 | +/** |
| 3058 | + * Send a warning either to the debug log or in a PHP error depending on |
| 3059 | + * $wgDevelopmentWarnings |
| 3060 | + * |
| 3061 | + * @param $msg String: message to send |
| 3062 | + * @param $callerOffset Integer: number of itmes to go back in the backtrace to |
| 3063 | + * find the correct caller (1 = function calling wfWarn, ...) |
| 3064 | + * @param $level Integer: PHP error level; only used when $wgDevelopmentWarnings |
| 3065 | + * is true |
| 3066 | + */ |
3057 | 3067 | function wfWarn( $msg, $callerOffset = 1, $level = E_USER_NOTICE ) { |
3058 | 3068 | $callers = wfDebugBacktrace(); |
3059 | 3069 | if( isset( $callers[$callerOffset+1] ) ){ |