fix(plugin): pre-update backup notifies on success, not only failure #221

Merged
jmiller merged 2 commits from fix/preupdate-notification into dev 2026-07-05 23:58:24 +00:00
Owner

Targeting dev.

Why "the pre-update popup notification isn't firing": runPreActionBackup() only called enqueueMessage() when the backup failed. On a successful pre-update backup it was completely silent — so nothing appeared.

Fix: surface every outcome using the BackupRunner status:

  • complete → success notice ("Pre-update backup completed successfully.")
  • warning → warning (local archive made, remote upload failed)
  • fail / exception → error

Now a pre-update backup always produces an admin notification. php -l clean.

Note on a progress popup

This is the notification (admin message banner). A live progress modal during the extension update — like "Backup Now" on the dashboard — is a separate, harder piece (#196): the update runs server-side in one request and can't drive the AJAX progress modal without injecting into com_installer's page. If you want that too, it's a bigger change; this PR makes the outcome visible in the meantime.

Also — confirm "Backup before update" is enabled in the component options; if it's off, runPreActionBackup() returns before doing anything.

https://claude.ai/code/session_01WbGBN9VyRK61zczYWcCQ2i

Targeting **dev**. **Why "the pre-update popup notification isn't firing":** `runPreActionBackup()` only called `enqueueMessage()` when the backup **failed**. On a successful pre-update backup it was completely silent — so nothing appeared. **Fix:** surface every outcome using the `BackupRunner` status: - `complete` → success notice ("Pre-update backup completed successfully.") - `warning` → warning (local archive made, remote upload failed) - `fail` / exception → error Now a pre-update backup always produces an admin notification. `php -l` clean. ## Note on a *progress* popup This is the notification (admin message banner). A live **progress modal** during the extension update — like "Backup Now" on the dashboard — is a separate, harder piece (#196): the update runs server-side in one request and can't drive the AJAX progress modal without injecting into com_installer's page. If you want that too, it's a bigger change; this PR makes the outcome visible in the meantime. Also — confirm **"Backup before update"** is enabled in the component options; if it's off, `runPreActionBackup()` returns before doing anything. https://claude.ai/code/session_01WbGBN9VyRK61zczYWcCQ2i
jmiller added 1 commit 2026-07-05 23:58:03 +00:00
fix(plugin): pre-update backup notifies on success too, not only failure
Universal: PR Check / Require Docs Update (pull_request) Has been skipped
Universal: PR Check / Wiki Update Reminder (pull_request) Has been skipped
Universal: PR Check / Branch Policy (pull_request) Successful in 3s
Generic: Project CI / Lint & Validate (pull_request) Successful in 17s
Universal: PR Check / Secret Scan (pull_request) Successful in 12s
Universal: Pre-Release / Build Pre-Release (${{ inputs.stability || github.ref_name }}) (push) Successful in 44s
Universal: PR Check / Validate PR (pull_request) Failing after 1m5s
Joomla: Metadata Validation / Validate Joomla Metadata (pull_request) Successful in 1m13s
Generic: Project CI / Tests (pull_request) Has been cancelled
Universal: PR Check / Build RC Package (pull_request) Has been cancelled
Universal: PR Check / Report Issues (pull_request) Has been cancelled
1a1c81550c
runPreActionBackup() only enqueued a message when the backup failed, so a
successful pre-update backup produced no admin notification at all. Now it
surfaces every outcome via the BackupRunner status: complete -> success,
warning (archive made but remote upload failed) -> warning, fail -> error.

Refs #192

Claude-Session: https://claude.ai/code/session_01WbGBN9VyRK61zczYWcCQ2i
jmiller added 1 commit 2026-07-05 23:58:18 +00:00
chore(version): pre-release bump to 02.57.09-dev [skip ci]
RC Revert / Rename rc/ back to dev/ (pull_request) Has been skipped
Branch Cleanup / Delete merged branch (pull_request) Successful in 3s
dfd4e77ade
jmiller merged commit e1f5afb301 into dev 2026-07-05 23:58:24 +00:00
jmiller deleted branch fix/preupdate-notification 2026-07-05 23:58:26 +00:00
Sign in to join this conversation.