mirror of
https://github.com/arcan1s/ahriman.git
synced 2026-10-20 03:37:59 +00:00
feat: show notification on hold action
This commit is contained in:
1 parent
7f28e47ac4
commit
9b65e01d2f
1 file changed
+1
@@ -126,6 +126,7 @@ export default function PackageInfoDialog({
|
||||
try {
|
||||
const newHeldStatus = !(status?.is_held ?? false);
|
||||
await client.service.servicePackageHold(localPackageBase, currentRepository, newHeldStatus);
|
||||
showSuccess("Success", `Package ${newHeldStatus ? "held" : "unheld"}`);
|
||||
void queryClient.invalidateQueries({ queryKey: QueryKeys.package(localPackageBase, currentRepository) });
|
||||
} catch (exception) {
|
||||
showError("Action failed", `Could not update hold status: ${ApiError.errorDetail(exception)}`);
|
||||
|
||||
Reference in new issue
Block a user