forked from miguel456/luke-bot
Updated command signature
This commit is contained in:
parent
83e87103bf
commit
03cd015f12
|
@ -11,7 +11,7 @@ class Gimme implements Command
|
|||
{
|
||||
use HasSignature;
|
||||
|
||||
public $signature = "gimme {what: What to give you. Can be a cat pic!} {quantity: How many cat pictures do you want?}";
|
||||
public $signature = "gimme {thing: What to give you} {quantity: How many cat pictures}";
|
||||
|
||||
|
||||
private $cats;
|
||||
|
@ -29,7 +29,7 @@ class Gimme implements Command
|
|||
throw new Exception('Sorry, but I can\'t send you more than 25 cat pictures at a time. What a cat lover!');
|
||||
}
|
||||
|
||||
switch($parameters['what']) {
|
||||
switch($parameters['thing']) {
|
||||
|
||||
case "cat":
|
||||
|
||||
|
@ -37,7 +37,7 @@ class Gimme implements Command
|
|||
try
|
||||
{
|
||||
// Many pictures will return a list of pictures, separated by new lines
|
||||
return $this->cats->getCatPicture($parameters['quantity'], "small");
|
||||
return $this->cats->getCatPicture($parameters['what'], "small");
|
||||
}
|
||||
catch (Exception $ex)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue