Big phpdoc fixes patch