# This patch file was generated by NetBeans IDE
# It uses platform neutral UTF-8 encoding and \n newlines.
--- HEAD
+++ Modified In Working Tree
@@ -864,7 +864,7 @@
   // Set the order ID
   if ($order) {
     $field_orderid = variable_get('uc_node_checkout_' . $node->type . '_field_orderid', FALSE);
-    if ($field_orderid) {
+    if ($field_orderid and $order->order_id != $node->{$field_orderid}[0]['value']) {
       $node->{$field_orderid}[0]['value'] = $order->order_id;
       $needs_save = TRUE;
     }
@@ -874,7 +874,7 @@
   $field_orderstatus = variable_get('uc_node_checkout_' . $node->type . '_field_orderstatus', FALSE);
   if ($field_orderstatus) {
     $orderstatus =& $node->{$field_orderstatus}[0]['value'];
-    if ($order) {
+    if ($order and $node->{$field_orderstatus}[0]['value'] != $order->order_status) {
       $orderstatus = $order->order_status;
       $needs_save = TRUE;
     }
@@ -886,7 +886,7 @@
 
   // Set the product ID
   $field_productid = variable_get('uc_node_checkout_' . $node->type . '_field_productid', FALSE);
-  if ($field_productid) {
+  if ($field_productid and $product->nid != $node->{$field_productid}[0]['value']) {
     $node->{$field_productid}[0]['value'] = $product->nid;
     $needs_save = TRUE;
   }

