Skip to content

Commit

Permalink
fix: Fix yargs compatibility (#61)
Browse files Browse the repository at this point in the history
Older versions of yargs only allow you to call conflicts() with two
arguments, not three. For greater compatibility, use the two-argument
version of the call.
  • Loading branch information
joeyparrish authored Dec 1, 2022
1 parent bb33cc6 commit 3d44c2d
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions backends/chromecast/chromecast-webdriver-cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,10 @@ yargs
'Either --url, --home, or --show-serial must be specified.',
type: 'boolean',
})
// You can't use both at once.
.conflicts('url', 'home', 'show-serial')
// You can't use more than one of these at once.
.conflicts('url', 'home')
.conflicts('home', 'show-serial')
.conflicts('url', 'show-serial')
.check((flags) => {
// Enforce that one mode is required.
if (!flags.url && !flags.home && !flags.showSerial) {
Expand Down

0 comments on commit 3d44c2d

Please sign in to comment.