FGRibreau/node-amqp-tool

Missing command [--queue | --exchange] --queue myQueue or --exchange myExchange

Closed this issue · 5 comments

I start amqp-tool with --queue flag but I get an error

Missing command [--queue | --exchange]
 --queue myQueue or --exchange myExchange

Either the error message is wrong: and instead of or

if(!argv.queue || !argv.exchange){
  console.error("Missing command [--queue | --exchange]");
  console.error("  --queue myQueue and --exchange myExchange");
  return;
}

Or the if condition is wrong: && instead of ||

if(!argv.queue && !argv.exchange){
  console.error("Missing command [--queue | --exchange]");
  console.error("  --queue myQueue or --exchange myExchange");
  return;
}

Hello,

What were you trying to achieve ? An export or an import ? You need both parameters for export if I remember correctly

I got the same issue with the examples in the README.md.

Would be nice to update the examples.

@pepijndevos I am sorry I don't have the time to fix it right now, could you send a pull request ?

Any news ?