Update Membership.php
authorSarah Gladstone <sepg@pogstone.com>
Tue, 29 Apr 2014 17:16:13 +0000 (10:16 -0700)
committerSarah Gladstone <sepg@pogstone.com>
Tue, 29 Apr 2014 17:16:13 +0000 (10:16 -0700)
Change compare to false to "empty" function

CRM/Member/Form/Membership.php

index c298cca5fd5f85ebbf21bd9327526b0b2f32f4b9..3d826f3ec495b394e3bb7b2a42736d64ca937355 100644 (file)
@@ -982,7 +982,7 @@ WHERE   id IN ( ' . implode(' , ', array_keys($membershipType)) . ' )';
            foreach($tmp_statuses as $cur_stat) {
               $status_ids[] = $cur_stat['id']; 
             }
-            if( $params['status_id'] == false || in_array( $params['status_id'] , $status_ids)  == false ) {
+            if( empty( $params['status_id'] ) || in_array( $params['status_id'] , $status_ids)  == false ) {
               $errors['status_id'] = ts('Please enter a status that does NOT represent a current membership status.');
               $errors['is_override']  = ts('This must be checked because you set an End Date for a lifetime membership');
             }