code: def update_freshness(self, ledger_id, ts):
          '''
          Updates the time at which the ledger was updated.
          Should be called whenever a txn for the ledger is ordered.
  
          :param ledger_id: the ID of the ledgers a txn was ordered for
          :param ts: the current time
          :return: None
          '''
          if ledger_id in self._ledger_freshness:
              self._ledger_freshness[ledger_id].last_updated = tf update_freshness(self, ledger_id, ts):
          '''
          Updates the time at which the ledger was updated.
          Should be called whenever a txn for the ledger is ordered.
  
          :param ledger_id: the ID of the ledgers a txn was ordered for
          :param ts: the current time
          :return: None
          '''
          if ledger_id in self._ledger_freshness:
              self._ledger_freshness[ledger_id].last_updated = ts
docs: Updates the time at which the ledger was updated.
          Should be called whenever a txn for the ledger is ordered.
  
          :param ledger_id: the ID of the ledgers a txn was ordered for
          :param ts: the current time
          :return: None