fix a bug with --interactive