@@ 88-101 (lines=14) @@ | ||
85 | $name = $input->getArgument('name'); |
|
86 | ||
87 | if (null !== $name) { |
|
88 | if (!$input->getOption('force')) { |
|
89 | $response = $dialog->askConfirmation( |
|
90 | $output, |
|
91 | sprintf( |
|
92 | '<comment>This will remove the %s queue, even if it has messages! Are you sure? </comment>', |
|
93 | $name |
|
94 | ), |
|
95 | false |
|
96 | ); |
|
97 | ||
98 | if (!$response) { |
|
99 | return 0; |
|
100 | } |
|
101 | } |
|
102 | ||
103 | return $this->destroyQueue($registry, $name); |
|
104 | } |
|
@@ 106-116 (lines=11) @@ | ||
103 | return $this->destroyQueue($registry, $name); |
|
104 | } |
|
105 | ||
106 | if (!$input->getOption('force')) { |
|
107 | $response = $dialog->askConfirmation( |
|
108 | $output, |
|
109 | '<comment>This will remove ALL queues, even if they have messages. Are you sure? </comment>', |
|
110 | false |
|
111 | ); |
|
112 | ||
113 | if (!$response) { |
|
114 | return 0; |
|
115 | } |
|
116 | } |
|
117 | ||
118 | foreach ($registry->all() as $queue) { |
|
119 | $this->destroyQueue($registry, $queue->getName()); |