Skip to content

Commit

Permalink
Parse all quotas from GETQUOTAROOT (#6280)
Browse files Browse the repository at this point in the history
  • Loading branch information
ledgr authored and alecpl committed May 5, 2018
1 parent 8477b88 commit 7dfbb62
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions program/lib/Roundcube/rcube_imap_generic.php
Original file line number Diff line number Diff line change
Expand Up @@ -3125,8 +3125,9 @@ public function getQuota($mailbox = null)
if (preg_match('/^\* QUOTA /', $line)) {
list(, , $quota_root) = $this->tokenizeResponse($line, 3);

while ($line) {
list($type, $used, $total) = $this->tokenizeResponse($line, 1);
$quotas = $this->tokenizeResponse($line, 1);
foreach (array_chunk($quotas, 3) as $quota) {
list($type, $used, $total) = $quota;
$type = strtolower($type);

if ($type && $total) {
Expand Down

0 comments on commit 7dfbb62

Please sign in to comment.