Fix deleting/moving folders from folders with name "0", "00", etc.
| | |
| | | // create a per-folder UIDs array |
| | | foreach ((array)$_uid as $uid) { |
| | | list($uid, $mbox) = explode('-', $uid, 2); |
| | | if (empty($mbox)) |
| | | if (!strlen($mbox)) |
| | | $mbox = $_mbox; |
| | | if ($uid == '*') |
| | | $result[$mbox] = $uid; |
| | |
| | | $target = rcube_utils::get_input_value('_target_mbox', rcube_utils::INPUT_POST, true); |
| | | |
| | | foreach (rcmail::get_uids() as $mbox => $uids) { |
| | | if ($mbox == $target) |
| | | if ($mbox === $target) |
| | | $copied++; |
| | | else |
| | | $copied += (int)$RCMAIL->storage->copy_message($uids, $target, $mbox); |
| | |
| | | |
| | | $success = true; |
| | | foreach (rcmail::get_uids() as $mbox => $uids) { |
| | | if ($mbox == $target) { |
| | | if ($mbox === $target) { |
| | | $count += count($uids); |
| | | } |
| | | else if ($RCMAIL->storage->move_message($uids, $target, $mbox)) { |