Update function declarations to adhere to PSR-2 standards

This commit is contained in:
Malcolm Fell 2013-06-30 12:33:34 +12:00
parent fa03534bb8
commit 91da073b45

View File

@ -327,7 +327,7 @@ echo my_function(); // => "Hello"
// A valid function name starts with a letter or underscore, followed by any // A valid function name starts with a letter or underscore, followed by any
// number of letters, numbers, or underscores. // number of letters, numbers, or underscores.
function add($x, $y = 1) { // $y is optional, and defaults to 2 function add ($x, $y = 1) { // $y is optional and defaults to 1
$result = $x + $y; $result = $x + $y;
return $result; return $result;
} }