diff --git a/CHANGELOG.md b/CHANGELOG.md index 40786b6e8..2bdec37b4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,7 @@ ### Changed - When `printHelpOnEmptyArgs` is `true` and no arguments are present, or when `invokeWithoutSubcommand` is `false` and no subcommand is present, `CliktCommand.main` will now exit with status code 1 rather than 0. - `restrictTo` now works with any `Comparable` value, not just `Number`. +- `CliktCommand.main` now accepts `Array`, not just `Array`. ### Fixed - Fixed option values being reset when calling multiple subcommands with `allowMultipleSubcommands=true` ([#190](https://github.com/ajalt/clikt/issues/190)) diff --git a/clikt/src/commonMain/kotlin/com/github/ajalt/clikt/core/CliktCommand.kt b/clikt/src/commonMain/kotlin/com/github/ajalt/clikt/core/CliktCommand.kt index c5eb4f5b2..fded140e2 100644 --- a/clikt/src/commonMain/kotlin/com/github/ajalt/clikt/core/CliktCommand.kt +++ b/clikt/src/commonMain/kotlin/com/github/ajalt/clikt/core/CliktCommand.kt @@ -295,7 +295,7 @@ abstract class CliktCommand( } } - fun main(argv: Array) = main(argv.asList()) + fun main(argv: Array) = main(argv.asList()) /** * Perform actions after parsing is complete and this command is invoked.