ui(server): fix used backup count (#3526)
* ui(server): fix used backup count * ui(server): refactor backup count code
This commit is contained in:
parent
7e91a33a67
commit
10b357b71e
7 changed files with 41 additions and 32 deletions
|
@ -58,6 +58,7 @@ export default ({ backup }: Props) => {
|
|||
.then(() => mutate(data => ({
|
||||
...data,
|
||||
items: data.items.filter(b => b.uuid !== backup.uuid),
|
||||
backupCount: data.backupCount - 1,
|
||||
}), false))
|
||||
.catch(error => {
|
||||
console.error(error);
|
||||
|
|
Reference in a new issue