src/Console/Routes/Controller.php
public function confirm($message, $default = false)
    {
        if ($this->interactive) {
            return Console::confirm($message, $default);
        }

        return resolve(true);
    }
public function confirm($message, $default = false)
    {
        if ($this->interactive) {
            return Console::confirm($message, $default);
        }

        return resolve(true);
    }
Asks user to confirm by typing y or n.

A typical usage looks like the following:

```php
if ($this->confirm("Are you sure?")) {
echo "user typed yes\n";
} else {
echo "user typed no\n";
}
```

@param string $message to echo out before waiting for user input
@param bool $default this value is returned if no selection is made.
@return ExtendedPromiseInterface with bool whether user confirmed.
Will return true if [[interactive]] is false.