php-cron-scheduler icon indicating copy to clipboard operation
php-cron-scheduler copied to clipboard

Intelephense suggestion issue

Open ekr3peeK opened this issue 3 years ago • 0 comments

Intelephense for VS Code, gets only partial suggestions when you are trying to use the following syntax:

$scheduler->php(...)
                ->everyMinute(...)
                ->when(...)

According to Intelephense the when function does not exist, because the everyMinute function which is in the trait is being documented as returning itself, and not the actual class where the trait was used:

     * @return self
     */
    public function everyMinute($minute = null)

This could be fixed if updating the @return documentation of the traits function to static, instead of self.

As I am using VS Code, I could not test this out, if the intelisens used by other IDEs behave the same on this issue, or not.

ekr3peeK avatar Jun 02 '21 09:06 ekr3peeK