Fix snap's channel option. (#3028)

This commit is contained in:
Felix Fontein 2021-07-19 03:36:59 +02:00 committed by GitHub
commit 7b9687f758
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 1 deletions

View file

@ -145,7 +145,7 @@ class Snap(CmdStateModuleHelper):
actionable_snaps=dict(fmt=lambda v: v),
state=dict(fmt=_state_map),
classic=dict(fmt="--classic", style=ArgFormat.BOOLEAN),
channel=dict(fmt=lambda v: [] if v == 'stable' else ['--channel', '{0}']),
channel=dict(fmt=lambda v: [] if v == 'stable' else ['--channel', '{0}'.format(v)]),
)
check_rc = False