This repository was archived by the owner on Jan 29, 2023. It is now read-only.
This repository was archived by the owner on Jan 29, 2023. It is now read-only.
Open
Description
Can I suggest a fix?
Line 947:
$extendedFieldValues[] = " `".$field."` = '".$modx->db->escape(stripslashes(trim($_POST[$field])))."'";
Change to something like this:
if( isset($_POST[$field]) ){
$extendedFieldValues[] = " `".$field."` = '".$modx->db->escape(stripslashes(trim($_POST[$field])))."'";
}
This should prevent a non-existent $_POST variable from setting the field value to an empty string.
Metadata
Metadata
Assignees
Labels
No labels