original_string: public function handleTrackCalculation($userId)
      {
          // Process any events
          $trackEngine = $this->getTrackEngine();
  
          // Places here instead of only in handle field update so it will run on new tracks too
          $this->assignTokensToRelations();
  
          if ($event = $trackEngine->getTrackCalculationEvent()) {
              return $event->processTrackCalculation($this, $userId);
          }
  
          return 0;
      }
code: public function handleTrackCalculation($userId)
      {
          // Process any events
          $trackEngine = $this->getTrackEngine();
  
          // Places here instead of only in handle field update so it will run on new tracks too
          $this->assignTokensToRelations();
  
          if ($event = $trackEngine->getTrackCalculationEvent()) {
              return $event->processTrackCalculation($this, $userId);
          }
  
          return 0;
      }
code_tokens: public function handleTrackCalculation ( $ userId ) { // Process any events $ trackEngine = $ this -> getTrackEngine ( ) ; // Places here instead of only in handle field update so it will run on new tracks too $ this -> assignTokensToRelations ( ) ; if ( $ event = $ trackEngine -> getTrackCalculationEvent ( ) ) { return $ event -> processTrackCalculation ( $ this , $ userId ) ; } return 0 ; }
docstring: Find out if there are track calculation events and delegate to the event if needed
  
  @param int $userId
docstring_tokens: Find out if there are track calculation events and delegate to the event if needed