Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 0.6.8

Bug #1264 Optional fields are never validated
Submitted: 2004-04-23 04:29 UTC
From: aashley at optimiser dot com Assigned: ieure
Status: Closed Package: Payment_Process
PHP Version: 5.0.0RC1 (Release Candidate 1) OS: Linux
Roadmaps: (Not assigned)    
Subscription  
Comments Add Comment Add patch


Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know! Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem : 35 - 28 = ?

 
 [2004-04-23 04:29 UTC] aashley at optimiser dot com
Description: ------------ Optional fields are never validated in Common::validate() patch to fix: --- /usr/share/pear/Payment/Process/Common.php 2004-04-13 15:45:48.000000000 +0800 +++ Common.php 2004-04-21 22:37:25.000000000 +0800 @@ -58,7 +58,7 @@ $func = '_validate'.ucfirst($field); // Don't validate unset optional fields - if (! $this->isRequired($field) && !strlen($this->field)) { + if (! $this->isRequired($field) && !strlen($this->$field)) { continue; }

Comments

 [2004-04-28 20:14 UTC] ieure
This bug has been fixed in CVS. In case this was a documentation problem, the fix will show up at the end of next Sunday (CET) on pear.php.net. In case this was a pear.php.net website problem, the change will show up on the website in short time. Thank you for the report, and for helping us make PEAR better.