Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F117891297
D5700.1775364497.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Authored By
Unknown
Size
2 KB
Referenced Files
None
Subscribers
None
D5700.1775364497.diff
View Options
diff --git a/src/app/DataMigrator/Driver/IMAP.php b/src/app/DataMigrator/Driver/IMAP.php
--- a/src/app/DataMigrator/Driver/IMAP.php
+++ b/src/app/DataMigrator/Driver/IMAP.php
@@ -238,7 +238,7 @@
// Get message flags
$header = $this->imap->fetchHeader($mailbox, (int) $uid, true, false, ['FLAGS']);
- if ($header === false) {
+ if (empty($header)) {
throw new \Exception("Failed to get IMAP message headers for {$mailbox}/{$uid}");
}
diff --git a/src/bootstrap/app.php b/src/bootstrap/app.php
--- a/src/bootstrap/app.php
+++ b/src/bootstrap/app.php
@@ -5,28 +5,6 @@
define('RCUBE_CHARSET', 'UTF-8');
}
-if (!function_exists('array_first')) {
- /**
- * Get first element from an array
- *
- * @param array $array Input array
- *
- * @return mixed First element if found, Null otherwise
- */
- function array_first($array)
- {
- // @phpstan-ignore-next-line
- if (is_array($array) && !empty($array)) {
- reset($array);
- foreach ($array as $element) {
- return $element;
- }
- }
-
- return null;
- }
-}
-
/*
|--------------------------------------------------------------------------
| Create The Application
diff --git a/src/composer.json b/src/composer.json
--- a/src/composer.json
+++ b/src/composer.json
@@ -17,6 +17,7 @@
"php": "^8.2",
"bacon/bacon-qr-code": "^2.0",
"barryvdh/laravel-dompdf": "^2.0.1",
+ "dedoc/scramble": "~0.10",
"doctrine/dbal": "^3.6",
"dyrynda/laravel-nullable-fields": "^4.3.0",
"garethp/php-ews": "~0.10.3",
@@ -38,7 +39,7 @@
"spatie/laravel-translatable": "^6.5",
"spomky-labs/otphp": "~10.0.0",
"stripe/stripe-php": "^10.7",
- "dedoc/scramble": "~0.10"
+ "symfony/polyfill-php85": "^1.33.0"
},
"require-dev": {
"code-lts/doctum": "dev-main",
diff --git a/src/include/rcube_imap_generic.php b/src/include/rcube_imap_generic.php
--- a/src/include/rcube_imap_generic.php
+++ b/src/include/rcube_imap_generic.php
@@ -2711,7 +2711,7 @@
* @param array $add_headers List of additional headers
* @param array $query_items List of additional items to fetch
*
- * @return bool|rcube_message_header Message data, False on error
+ * @return rcube_message_header|null|bool Message data, False on error, Null if not found
*/
public function fetchHeader($mailbox, $id, $is_uid = false, $bodystr = false, $add_headers = [], $query_items = [])
{
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Apr 5, 4:48 AM (5 h, 17 m ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
18823165
Default Alt Text
D5700.1775364497.diff (2 KB)
Attached To
Mode
D5700: Fix an attempt to read property "flags" on null
Attached
Detach File
Event Timeline