backdrop-contrib / backup_migrate

Port of the Drupal backup_migrate module to Backdrop
GNU General Public License v2.0
7 stars 14 forks source link

[8.1] Deprecated function: explode(): Passing null to parameter #2 ($string) #131

Closed argiepiano closed 9 months ago

argiepiano commented 9 months ago

This is thrown when backing up the entire site and db.

Deprecated function: explode(): Passing null to parameter #2 ($string) of type string is deprecated in backup_file->set_file_info() (line 521 of /Users/XXX/Sites/localhost/bdtesting/modules/backup_migrate/includes/files.inc).

The problem is that backup_file::set_file_info() expects a file name as part of the received array. But backup_migrate_files_destination_archivesource::get_db() doesn't pass a filename, since the file has already been initialized previously when backing up the site files. The solution is to avoid doing the explode if the array is empty.

argiepiano commented 9 months ago

PR #132