for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* Created by Maciej Paprocki for Bureau-VA.
* Date: 18/02/2016
* Project Name: MaciekPaprocki\WordpressGuzzle
* Time: 12:12
*/
namespace BureauVa\WordpressGuzzle\Helper;
* Class StringHelper
* @package MaciekPaprocki\WordpressGuzzle
class StringHelper
{
* converts to camel case. Shamefully stolen from
* @param $str
* @param array $noStrip
$noStrip
This check looks for PHPDoc comments describing methods or function parameters that do not exist on the corresponding method or function.
Consider the following example. The parameter $italy is not defined by the method finale(...).
$italy
finale(...)
/** * @param array $germany * @param array $island * @param array $italy */ function finale($germany, $island) { return "2:1"; }
The most likely cause is that the parameter was removed, but the annotation was not.
* @return mixed|string
public static function camelCase($str)
// non-alpha and non-numeric characters become spaces
$str = preg_replace('/[^\w\d]+/', ' ', $str);
$str = trim($str);
// uppercase the first character of each word
$str = ucwords($str);
$str = str_replace(" ", "", $str);
$str = lcfirst($str);
return $str;
}
This check looks for PHPDoc comments describing methods or function parameters that do not exist on the corresponding method or function.
Consider the following example. The parameter
$italy
is not defined by the methodfinale(...)
.The most likely cause is that the parameter was removed, but the annotation was not.