Skip to content

Commit

Permalink
Filter out non-provider Providers from dialoguer prompt
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesmcm committed Apr 11, 2024
1 parent 2d2b63a commit e81cf6a
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/sync.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@ use crate::args::WrappedArg;
pub fn sync_menu(uiclient: &dyn UiClient) -> anyhow::Result<()> {
let variants = WrappedArg::<VpnProvider>::value_variants()
.iter()
.filter(|x| x.to_variant() != VpnProvider::Custom)
.filter(|x| {
![VpnProvider::Custom, VpnProvider::None, VpnProvider::Warp].contains(&x.to_variant())
})
.map(|x| x.to_variant().to_string())
.collect::<Vec<String>>();

Expand Down

0 comments on commit e81cf6a

Please sign in to comment.