dev/financial#50 - Fix contributions getting overwritten
authorPatrick Figel <pfigel@greenpeace.org>
Tue, 14 May 2019 13:03:19 +0000 (15:03 +0200)
committerPatrick Figel <pfigel@greenpeace.org>
Thu, 13 Jun 2019 21:25:56 +0000 (23:25 +0200)
This fixes an issue where contributions may be overwritten when users
open an existing contribution after opening the "Record Contribution"
form (but before actually submitting it).

CRM/Contribute/Form/Contribution.php

index 0121cd1dbb9db75124df4539b2fec61df6cda8df..6632df7404aaf07c92c5401cfc19cbdf90ecf4df 100644 (file)
@@ -250,7 +250,7 @@ class CRM_Contribute_Form_Contribution extends CRM_Contribute_Form_AbstractEditP
     $this->assign('action', $this->_action);
 
     // Get the contribution id if update
-    $this->_id = CRM_Utils_Request::retrieve('id', 'Positive', $this);
+    $this->_id = CRM_Utils_Request::retrieve('id', 'Positive');
     if (!empty($this->_id)) {
       $this->assignPaymentInfoBlock();
       $this->assign('contribID', $this->_id);