Verified Commit f35f6ba8 authored by Jelle van der Waa's avatar Jelle van der Waa 🚧
Browse files

Resolve SQL Error when deleting an account

The account deletion code tries to remove user from PackageNotifications
using the wrong column UsersID to identify the user by id. In the
PackagePackageNotifications table the foreign key is called UserID. In
the future ideally this would be unified into UserID for all tables.

Closes: #12
parent 21c45781
Pipeline #5990 passed with stage
in 1 minute and 3 seconds
......@@ -940,7 +940,7 @@ function user_delete($id) {
$fields_delete = array(
array("Sessions", "UsersID"),
array("PackageVotes", "UsersID"),
array("PackageNotifications", "UsersID")
array("PackageNotifications", "UserID")
);
$fields_set_null = array(
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment