working before async refactor
[ldk-sample] / src / cli.rs
index 21c40236e18e9ec6f0793102e4888eae452cf319..ca1b84fed66fbe6f64f3cf4d63ddc141c0978ace 100644 (file)
@@ -160,10 +160,10 @@ pub(crate) fn poll_for_user_input(
 
                                        // let private_channel = match words.next().as_ref().map(String::as_str) {
                                        let announce_channel = match words.next() {
-                                               Some("--public") | Some("--public=true") | Some("--public true") => true,
-                                               Some("--public=false") | Some("--public false") => false,
+                                               Some("--public") | Some("--public=true") => true,
+                                               Some("--public=false") => false,
                                                Some(_) => {
-                                                       println!("ERROR: invalid `--public` command format");
+                                                       println!("ERROR: invalid `--public` command format. Valid formats: `--public`, `--public=true` `--public=false`");
                                                        print!("> ");
                                                        io::stdout().flush().unwrap();
                                                        continue;