uboslinux / ubos-admin

UBOS administration tools
Other
15 stars 3 forks source link

Rare ZipFileBackup restore error #854

Closed jernst closed 5 months ago

jernst commented 2 years ago

Here is the problem (Line 240, ZipFileBackup.pm):

    foreach my $siteJsonFile ( $self->{zip}->membersMatching( "$zipFileSiteEntry/.*\.json" )) {

This regex apparently matches a path such as:

appconfigs/ace6730c5ab80d998184f6342c57736abcf8148f1/nextcloud/apache2/datadir/jernst/files/CCPA/Facebook/2020-01-06/facebook-johannesernst/apps_and_websites/apps_and_websites.json

which of course screws up everything, because we are really looking for files such as sites/s1234.json.

Let's try this instead:

    foreach my $siteJsonFile ( $self->{zip}->membersMatching( "^$zipFileSiteEntry/s[0-9a-f]+\.json" )) {