- $attempts = 0;
- while ($censor && $attempts < 3) {
- $clean = $plugin->cleanString($item->name);
- if ($item->name != $clean) {
- $attempts++;
- $item = $this->getItem($database, $table, $match);
- } else {
- $censor = false;
- }
- }
- if ($censor && $attempts == 3) {
- $this->doAction($this->event->getSource(), 'shrugs.');
+ $clean = $plugin->cleanString($item->name);
+ if ($item->name != $clean) {
+ $attempts++;
+ $item = $this->getItem($database, $table, $match);
+ } else {
+ $censor = false;