Mercurial > hg > rc2
comparison program/lib/Roundcube/rcube_imap_generic.php @ 17:dd5ed6ef69c9
Slowly cleaning up more php8 Warnings/deprecations
| author | Charlie Root |
|---|---|
| date | Mon, 06 Oct 2025 12:20:32 -0400 |
| parents | 1866b439e6d3 |
| children | b631c1c7a3ce |
comparison
equal
deleted
inserted
replaced
| 16:1866b439e6d3 | 17:dd5ed6ef69c9 |
|---|---|
| 1675 * @return int Number of messages, False on error | 1675 * @return int Number of messages, False on error |
| 1676 */ | 1676 */ |
| 1677 public function countUnseen($mailbox) | 1677 public function countUnseen($mailbox) |
| 1678 { | 1678 { |
| 1679 // Check internal cache | 1679 // Check internal cache |
| 1680 $cache = $this->data['STATUS:'.$mailbox]; | 1680 $cache = ($this->data['STATUS:'.$mailbox]??null); |
| 1681 if (!empty($cache) && isset($cache['UNSEEN'])) { | 1681 if (!empty($cache) && isset($cache['UNSEEN'])) { |
| 1682 return (int) $cache['UNSEEN']; | 1682 return (int) $cache['UNSEEN']; |
| 1683 } | 1683 } |
| 1684 | 1684 |
| 1685 // Try STATUS (should be faster than SELECT+SEARCH) | 1685 // Try STATUS (should be faster than SELECT+SEARCH) |
