Crummy\Phlack\Bot\ExpressionBot::execute PHP Method

execute() public method

public execute ( Crummy\Phlack\WebHook\CommandInterface $command ) : Reply
$command Crummy\Phlack\WebHook\CommandInterface
return Crummy\Phlack\WebHook\Reply\Reply
    public function execute(CommandInterface $command)
    {
        try {
            $response = (string) $this->evaluate($command, $this->getValues($command));
        } catch (SyntaxError $badSyntax) {
            $response = $badSyntax->getMessage();
        }
        return $this->say($response);
    }