code: public function onUpdate(ResourceEventInterface $event)
      {
          $sale = $this->getSaleFromEvent($event);
  
          $this->preventForbiddenChange($sale);
  
          if ($this->handleUpdate($sale)) {
              $this->persistenceHelper->persistAndRecompute($sale, false);
          }
  
          // Schedule content change
          if ($this->persistenceHelper->isChanged($sale, 'currency')) {
              $sale->setExchangeRate(null); // Clear exchange rate
              $this->scheduleContentChangeEvent($sale);
          } elseif ($this->persistenceHelper->isChanged($sale, ['vatDisplayMode', 'paymentTerm', 'shipmentAmount'])) {
              $this->scheduleContentChangeEvent($sale);
          }
  
          // Handle addresses changes
          /* TODO ? if ($this->persistenceHelper->isChanged($sale, ['deliveryAddress', 'sameAddress'])) {
              $this->scheduleAddressChangeEvent($sale);
          }*/
      }
docs: Update event handler.
  
  @param ResourceEventInterface $event