// $Id: ca.ca.inc,v 1.1.2.7 2009/04/14 13:51:16 islandusurper Exp $
Line 260
'#default_values' => $setting['field'],
Line 239
function ca_condition_node_field_comparison_form($form_state, $settings = array()) {

$setting and $settings
Looks like a typo

// $Id: uc_2checkout.module,v 1.6.2.6 2009/04/18 07:29:19 islandusurper Exp $
Line 219
$data['c_description_'. $i] = $desc;
is it a property of $product? $product->desc

// $Id: uc_2checkout.pages.inc,v 1.1.2.2 2008/11/07 21:13:29 islandusurper Exp $
Line 54
uc_order_comment_save($order_id, 0, t('!type payment is pending approval at 2Checkout.com.', array('!type' => $_POST['pay_method'] == 'CC' ? t('Credit card') : t('eCheck'))), 'admin');
$order_id
maybe $order->order_id

I could go on; but I think it might be easier if you use Eclipse to find them; if you want I can list them all out
// $Id: uc_authorizenet.admin.inc,v 1.1.2.1 2008/11/07 21:13:22 islandusurper Exp $
line 30 $form['cc_data'] += uc_payment_method_credit_form(array(), $order);
// $Id: uc_authorizenet.module,v 1.4.2.7 2009/04/18 07:29:19 islandusurper Exp $
Line 867 unset($update['paymentSchedule']);
should be $updates
// $Id: uc_authorizenet.pages.inc,v 1.1.2.1 2008/11/07 21:13:22 islandusurper Exp $
Line 152 $form_state['redirect'] = 'user/'. $uid;
// $Id: uc_credit.admin.inc,v 1.1.2.3 2009/04/18 07:29:17 islandusurper Exp $
Line 12 $output = l(t('Return to order view screen.'), 'admin/store/orders/'. $order_id);
maybe $order->order_id
// $Id: uc_cybersource.module,v 1.4.2.6 2009/04/18 07:29:16 islandusurper Exp $
Line 340 $request['orderNumber'] = $order_id;
maybe $order->order_id
// $Id: uc_google_checkout.module,v 1.1.2.5 2009/04/18 07:29:16 islandusurper Exp $
Line 830 switch ($cvn_response) {
Maybe $cvs_response instead of $cvn_response
// $Id: uc_paypal.module,v 1.5.2.12 2009/04/18 07:29:16 islandusurper Exp $
Line 616 'AMT' => uc_price($order->order_total, $checkout, $options),
$checkout
// $Id: uc_recurring.module,v 1.7.2.15 2009/04/18 07:29:16 islandusurper Exp $
line 130 if (uc_recurring_find_fees($order) == array()) {
$order isn't passed in; maybe a global?
// $Id: uc_shipping.module,v 1.6.2.9 2009/04/18 07:29:15 islandusurper Exp $
line 228 $output .= '

'. t('Package %id:', array('%id' => $package_id)) .'

';
$package_id maybe $package->package_id
// $Id: uc_attribute.admin.inc,v 1.1.2.9 2009/04/18 07:29:19 islandusurper Exp $
line 410 drupal_goto('admin/store/attributes/'. $aid .'/options');
$aid should be $attribute->aid
// $Id: uc_file.admin.inc,v 1.1.2.6 2009/04/02 21:01:45 islandusurper Exp $
line 349 $result = $name('upload_validate', array('file_object' => $temp_file, 'form_id' => $form_id, 'form_state' => $form_state));
and
line 366 $result = $name('validate', array('form_id' => $form_id, 'form_state' => $form_state));
and Line 411, 434
$form_id maybe $form->form_id

// $Id: uc_file.module,v 1.2.2.14 2009/04/02 21:01:45 islandusurper Exp $
line 708 return $form;
$form not passed in or set

There are a lot more; I don't know how you want me to report this; all at once isn't ideal but there are too many; maybe I should look at nightly code; let me know how or if I can help.

Thanks; love this module; would like to see it get even better.

Jeff

CommentFileSizeAuthor
#3 445596.patch899 bytesIsland Usurper
#2 uc_variable_fixes.patch6.21 KBrszrama
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

rszrama’s picture

This may be a bit much to ask, but is it possible for you to make corrections on the ones you know are typos and submit that in patch format? It's kind of hard to make sense of the post after a while. For ones you're not sure of, you can leave those open to our investigation.

(fwiw, I fixed the typo in the first one for ca.ca.inc just now. Thanks!)

rszrama’s picture

Status: Active » Needs work
FileSize
6.21 KB

Ok, so actually, we're trying to push out a release, so I addressed a lot of these manually. Some where already addressed or were simply variables that weren't initialized properly and were meant to return empty values. The two I didn't touch are the Google Checkout one (because there are discrepancies in the messages and variable names that I don't know about) and the file.admin.inc ones because $form is an array not an object. That fix will need a little more consideration.

I probably won't do these manually again. Also, be sure you update to the latest Bzr version or maybe the RC2 to make sure the ones that are fixed aren't duplicated. Actually, I can also attach a patch here. : D

Island Usurper’s picture

Status: Needs work » Fixed
FileSize
899 bytes

Here's the fixes for Google Checkout and uc_file.admin.inc.

Since these changes have been committed, I'm marking this fixed. Jeff, if you want to make a patch for any more things you find, you can reopen this issue and post it up.

jflesher’s picture

Thanks; I wasn't trying to overwhelm you; I just wanted to post this and see how to go about dealing with them; I know some programmers will use variables and not set them; then check to see if that are set using isset; I don't agree with this approach for this reason alone; it looks like a bug; I'd rather set it to null and then look to see if its still null (false will work also).

Writing patches are fine once I know one is needed and its just not a poorly written function depending on things not being set; this would required a patch for that also; Pandora's box; best to ask first; I didn't debug these functions and I would have to step thru each line of code to follow the logic; which I don't mind doing; but was beyond what I needed to do at the moment; which was just to report them and see if they needed to be fixed and how I should report them too you.

I'll load the latest dev version next time I take a look.

Thanks; this program is great; I just want to help out as much as I can.

rszrama’s picture

Your help is greatly appreciated! Who knows how long those typos have been in there without being reported. I didn't even know an IDE could catch things like that. : P

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.