Scrutinizer commets.

This commit is contained in:
jgen 2017-03-12 14:29:35 -07:00
parent 44bead8b92
commit 7bd581b530
4 changed files with 34 additions and 2 deletions

View file

@ -1265,7 +1265,7 @@ function add_image($tmpname, $filename, $tags) {
*
* @param int $orig_width
* @param int $orig_height
* @return int[]
* @return integer[]
*/
function get_thumbnail_size(/*int*/ $orig_width, /*int*/ $orig_height) {
global $config;

View file

@ -433,8 +433,20 @@ function endsWith(/*string*/ $haystack, /*string*/ $needle) {
}
if(!function_exists("mb_strlen")) { // D:
/**
* @param string $str
*/
function mb_strlen($str) {return strlen($str);}
/**
* @param string $enc
*/
function mb_internal_encoding($enc) {}
/**
* @param string $str
*/
function mb_strtolower($str) {return strtolower($str);}
}
@ -1028,6 +1040,10 @@ function transload($url, $mfile) {
}
if (!function_exists('http_parse_headers')) { #http://www.php.net/manual/en/function.http-parse-headers.php#112917
/**
* @param string $raw_headers
*/
function http_parse_headers ($raw_headers){
$headers = array(); // $headers = [];
@ -1157,9 +1173,21 @@ function log_msg(/*string*/ $section, /*int*/ $priority, /*string*/ $message, $f
}
// More shorthand ways of logging
/**
* @param string $section
*/
function log_debug( /*string*/ $section, /*string*/ $message, $flash=false, $args=array()) {log_msg($section, SCORE_LOG_DEBUG, $message, $flash, $args);}
/**
* @param string $section
*/
function log_info( /*string*/ $section, /*string*/ $message, $flash=false, $args=array()) {log_msg($section, SCORE_LOG_INFO, $message, $flash, $args);}
/**
* @param string $section
*/
function log_warning( /*string*/ $section, /*string*/ $message, $flash=false, $args=array()) {log_msg($section, SCORE_LOG_WARNING, $message, $flash, $args);}
/**
* @param string $section
*/
function log_error( /*string*/ $section, /*string*/ $message, $flash=false, $args=array()) {log_msg($section, SCORE_LOG_ERROR, $message, $flash, $args);}
function log_critical(/*string*/ $section, /*string*/ $message, $flash=false, $args=array()) {log_msg($section, SCORE_LOG_CRITICAL, $message, $flash, $args);}

View file

@ -494,6 +494,10 @@ class Wiki extends Extension {
/**
* callback function to format the diffence-lines with your 'style'
* @param integer $nr1
* @param integer $nr2
* @param string $stat
* @return string
*/
private function formatline( $nr1, $nr2, $stat, &$value ) { #change to $value if problems
if(trim($value) == "") {

View file

@ -241,7 +241,7 @@ EOD;
/**
* @param string $link
* @param null|string $desc
* @param string $desc
* @param string[] $pages_matched
* @return null|string
*/