svn: /web/doc-editor/trunk/php/ AccountManager.php

[email protected] (Yannick Torres)
Newsgroups php.doc.web
Message-ID <[email protected]>
yannick                                  Wed, 26 May 2010 21:17:37 +0000

Revision: http://svn.php.net/viewvc?view=revision&revision=299835

Log:
Fix eraseData method

Changed paths:
    U   web/doc-editor/trunk/php/AccountManager.php

Modified: web/doc-editor/trunk/php/AccountManager.php
===================================================================
--- web/doc-editor/trunk/php/AccountManager.php	2010-05-26 21:11:06 UTC (rev 299834)
+++ web/doc-editor/trunk/php/AccountManager.php	2010-05-26 21:17:37 UTC (rev 299835)
@@ -454,18 +454,19 @@
      */
     public function eraseData()
     {
+        $db = DBConnection::getInstance();

         $s = sprintf(
-            'DELETE FROM `commitMessage` WHERE `userID`="%s"',
-            $this->userID
+            'DELETE FROM `commitMessage` WHERE `user`="%s"',
+            $this->vcsLogin
         );
-        DBConnection::getInstance()->query($s);
+        $db->query($s);

         $s = sprintf(
             'DELETE FROM `users` WHERE `userID`="%s"',
             $this->userID
         );
-        DBConnection::getInstance()->query($s);
+        $db->query($s);
     }

     /**
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.