Fix bug with instanceof

The ```$task``` variable is a string. And if its value is a class name which extends ```Rocketeer\Traits\Task```, instanceof will return ```true``` (see [documentation](http://www.php.net/manual/en/language.operators.type.php)) and method will return a string instead of expected object.