• Resolved fijisunshine

    (@fijisunshine)


    Updraft works great for me for php 7.4. But for php 8.0, my backups fail with this error:

    PHP Fatal error: Uncaught TypeError: max(): Argument #1 ($value) must be of type array, int given in … /plugins/updraftplus/class-updraftplus.php:2278

    I’m using the Premium version 2.16.43.24.

    Can you assist? Thank you

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author David Anderson

    (@davidanderson)

    Hi,

    If you edit that named file and line, and change it to…

    
    $useful_checkin = max($this->jobdata_get('useful_checkin', 0), max((array) $this->jobdata_get('useful_checkins', 0)));
    

    … then does the problem then go away?

    David

    Thread Starter fijisunshine

    (@fijisunshine)

    Thank you, David. Yes, that resolved that fatal error. However, now I get another fatal error further down in the same php file:

    PHP Fatal error (Error) has occurred during backupnow subaction. Error Message: Undefined constant “DOING_CRON” (Code: 0, line 2938 in … /plugins/updraftplus/class-updraftplus.php)

    Plugin Author David Anderson

    (@davidanderson)

    Hi,

    Hopefully near the start of next week we will have a new release which fixes some issues with PHP 8.0 compatibility which have come to light. Please stay tuned…

    David

    Thread Starter fijisunshine

    (@fijisunshine)

    Thank you, David. I just updated to the latest version of the plugin and it appears to now work with php 8.0.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘PHP 8 issue: Backup fails due to fatal error’ is closed to new replies.