System Patches package: system_patches_edit.php - Patch contents is cleared when error happens
Add a new patch, then fill 'patch contents' with a patch and 'URL/Commit ID' with invalid data then press 'Save'.
It'll report error and remove content from 'patch contents'
Updated by Steve Beaver almost 6 years ago
- Subject changed from System Patches: Patch contents is cleared when error happens to System Patches package: system_patches_edit.php - Patch contents is cleared when error happens
- Status changed from New to Assigned
- Assignee changed from Steve Beaver to Jim Pingle
It would appear that this is due to the patch being base64 encoded when saved to the config (no error) but being plain text when the page reloads after an error.
This is a simple way to fix it:
system_patches_edit.php line 184:
$patchtext = new Form_Textarea( 'patch', 'Patch Contents', $input_errors ? $pconfig['patch'] : base64_decode($pconfig['patch']) );