Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Helmo
ISPConfig 3
Commits
a27954c5
Commit
a27954c5
authored
Sep 12, 2018
by
Florian Schaal
Browse files
fixed sql-query for master-server for mail-backups
parent
a02ec6b0
Changes
2
Show whitespace changes
Inline
Side-by-side
server/lib/classes/cron.d/500-backup_mail.inc.php
View file @
a27954c5
...
...
@@ -242,7 +242,7 @@ class cronjob_backup_mail extends cronjob {
if
(
!
is_file
(
$mail_backup_dir
.
'/'
.
$backup
[
'filename'
])){
$sql
=
"DELETE FROM mail_backup WHERE server_id = ? AND parent_domain_id = ? AND filename = ?"
;
$app
->
db
->
query
(
$sql
,
$conf
[
'server_id'
],
$backup
[
'parent_domain_id'
],
$backup
[
'filename'
]);
if
(
$app
->
db
->
dbHost
!=
$app
->
dbmaster
->
dbHost
)
$app
->
dbmaster
->
query
(
$sql
);
if
(
$app
->
db
->
dbHost
!=
$app
->
dbmaster
->
dbHost
)
$app
->
dbmaster
->
query
(
$sql
,
$conf
[
'server_id'
],
$backup
[
'parent_domain_id'
],
$backup
[
'filename'
]
);
}
}
}
...
...
server/plugins-available/backup_plugin.inc.php
View file @
a27954c5
...
...
@@ -296,7 +296,7 @@ class backup_plugin {
unlink
(
$mail_backup_file
);
$sql
=
"DELETE FROM mail_backup WHERE server_id = ? AND parent_domain_id = ? AND filename = ?"
;
$app
->
db
->
query
(
$sql
,
$conf
[
'server_id'
],
$mail_backup
[
'parent_domain_id'
],
$mail_backup
[
'filename'
]);
if
(
$app
->
db
->
dbHost
!=
$app
->
dbmaster
->
dbHost
)
$app
->
dbmaster
->
query
(
$sql
);
if
(
$app
->
db
->
dbHost
!=
$app
->
dbmaster
->
dbHost
)
$app
->
dbmaster
->
query
(
$sql
,
$conf
[
'server_id'
],
$mail_backup
[
'parent_domain_id'
],
$mail_backup
[
'filename'
]
);
$app
->
log
(
'unlink '
.
$backup_dir
.
'/'
.
$mail_backup
[
'filename'
],
LOGLEVEL_DEBUG
);
}
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment