mirror of
https://github.com/pelican-dev/panel.git
synced 2026-05-04 18:00:48 +03:00
[PR #2033] [MERGED] fix: plugin migration rollback and cache clearing on uninstall #1721
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/pelican-dev/panel/pull/2033
Author: @PalmarHealer
Created: 12/21/2025
Status: ✅ Merged
Merged: 1/4/2026
Merged by: @Boy132
Base:
main← Head:palmarhealer/fix-plugin-migration📝 Commits (5)
c4d101cfix: replacemigrate:rollbackwithmigrate:resetand clear cached components after plugin updatesd435c6breplace Artisan calls with direct usage ofMigratorandSeederfor improved error handling and code clarityc171d36remove redundantoptimize:clearArtisan call fromPluginService6f1f888Merge branch 'main' into palmarhealer/fix-plugin-migrationc8e6f71small cleanup📊 Changes
1 file changed (+6 additions, -1 deletions)
View changed files
📝
app/Services/Helpers/PluginService.php(+6 -1)📄 Description
Fixes two critical bugs in the plugin uninstallation process that caused incomplete migration rollback and cache-related errors.
The
rollbackPluginMigrations()method usedmigrate:rollback, which only rolls back the last batch of migrations. If a plugin had migrations run across multiple batches (e.g., initial install in batch 50, update adds migration in batch 75), only the most recent batch was rolled back, leaving orphaned tables and columns in the database.After uninstalling a plugin, users encountered "Table not found" errors (e.g.,
SQLSTATE[42S02]: Base table or view not found).🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.