usmanhalalit / pixie

Database query builder for PHP, framework agnostic, lightweight and expressive.
MIT License
671 stars 179 forks source link

Fix PHP Doc Blocks #150

Open DarkMukke opened 8 years ago

DarkMukke commented 8 years ago

There seem to be many PHP Doc block incorrectly defined.

Eg :

class QueryBuilderHandler
{
   ...
    /**
     * @var null|PDOStatement
     */
    protected $pdoStatement = null;

    ...
    /**
     * @param $tables Single table or multiple tables as an array or as
     *                multiple parameters
     *
     * @return static
     */
    public function table($tables)
    {

needs to be

class QueryBuilderHandler
{
   ...
    /**
     * @var null|\PDOStatement
     */
    protected $pdoStatement = null;

    ...
    /**
     * @param string|array $tables Single table or multiple tables as an array or as
     *                multiple parameters
     *
     * @return static
     */
    public function table($tables)
    {

on a side note, in php 5.6 we should use splat vs func_get_args

DarkMukke commented 8 years ago

IF you want i can create a PR for that as I already fixed it locally

TCB13 commented 7 years ago

@DarkMukke go ahead. Thank you.

TCB13 commented 7 years ago

This make my #167 a duplicate. You've the code, just PR.

DarkMukke commented 7 years ago

The PR is not perfect though, it fails a test and I did this too long ago to remember why. I had to re-fork and make some changes so it took me a bit to get around to do it.

TCB13 commented 7 years ago

@DarkMukke I noticed there are other additional changes not related to the DocBlocks. What about just committing DocBlock changes right now and ignore everything else? 👍

DarkMukke commented 7 years ago

Right, that's how I had it in my local, Will make a small PR for just dock blocks

TCB13 commented 6 years ago

@DarkMukke any news on the smaller just DocBlock PR?

DarkMukke commented 6 years ago

@TCB13 been on holiday (off-line), it's on my todo-list

allejo commented 6 years ago

Any updates on this?

DarkMukke commented 6 years ago

Oh woops, i have the commit, let make it a PR

vikkio88 commented 6 years ago

this is fixed by #183 https://github.com/usmanhalalit/pixie/pull/183/files#diff-4d19ae281a7c0cb6c93d185dbb1108ffR447

vikkio88 commented 6 years ago

@DarkMukke you using phpstorm arent you? LoL I found this annoying to and fixed it while fixing another bug

TCB13 commented 6 years ago

Yeah @vikkio88 it is true. @DarkMukke can you check if the changes by @vikkio88 at 220b920904b9f60a7d61eba9554d936f4fda7977 completely fix this? In my opinion they do.

vikkio88 commented 6 years ago

I tested in my local env and they did. but is good to have another pair of eyes on it