Browse Source

Fix SQL issue that shouldn't be happening

spaghetti 7 years ago
parent
commit
b773278a7f
1 changed files with 2 additions and 1 deletions
  1. 2
    1
      sections/torrents/nonwikiedit.php

+ 2
- 1
sections/torrents/nonwikiedit.php View File

@@ -104,7 +104,8 @@ foreach ($Artists as $Artist) {
104 104
       INSERT INTO torrents_artists
105 105
       (GroupID, ArtistID, UserID)
106 106
       VALUES
107
-      (".$GroupID.", ".$ArtistID.", ".$LoggedUser['ID'].")");
107
+      (".$GroupID.", ".$ArtistID.", ".$LoggedUser['ID'].")
108
+      ON DUPLICATE KEY UPDATE UserID=".$LoggedUser['ID']); // Why does this even happen
108 109
     $Cache->delete_value('artist_groups_'.$ArtistID);
109 110
   }
110 111
 }

Loading…
Cancel
Save