I am building a function in a custom module, and I want to be able to execute only a specific part of that function. 

I am starting with the [hook\_node\_api](http://api.drupal.org/api/drupal/developer--hooks--core.php/function/hook_nodeapi/6) to see if an event occurs, and if that event occurs, I want to execute a only a specific part of that custom function.

```
function mymodule_nodeapi(&$node, $op, $a3 = NULL, $a4 = NULL) {
  switch ($op) {

    case 'presave'
    if (  $node->type == 'property' ){
        $old = node_load($node->nid);
        if($old->field_realtor_reference[0]['uid'] == NULL && $node->field_realtor_reference[0]['uid'] !== NULL){
               mymodule_tn_complete($node);  
        }
      }

      break;
  } 
}  

function mymodule_tn_complete( $node)
{
  //Do something 
  //Do Something Else

}

```