original_string: public function getMedia(NodeInterface $node) {
      if (!$this->entityTypeManager->getStorage('field_storage_config')->load('media.' . self::MEDIA_OF_FIELD)) {
        return [];
      }
      $mids = $this->entityQuery->get('media')->condition(self::MEDIA_OF_FIELD, $node->id())->execute();
      if (empty($mids)) {
        return [];
      }
      return $this->entityTypeManager->getStorage('media')->loadMultiple($mids);
    }
code: public function getMedia(NodeInterface $node) {
      if (!$this->entityTypeManager->getStorage('field_storage_config')->load('media.' . self::MEDIA_OF_FIELD)) {
        return [];
      }
      $mids = $this->entityQuery->get('media')->condition(self::MEDIA_OF_FIELD, $node->id())->execute();
      if (empty($mids)) {
        return [];
      }
      return $this->entityTypeManager->getStorage('media')->loadMultiple($mids);
    }
code_tokens: public function getMedia ( NodeInterface $ node ) { if ( ! $ this -> entityTypeManager -> getStorage ( 'field_storage_config' ) -> load ( 'media.' . self :: MEDIA_OF_FIELD ) ) { return [ ] ; } $ mids = $ this -> entityQuery -> get ( 'media' ) -> condition ( self :: MEDIA_OF_FIELD , $ node -> id ( ) ) -> execute ( ) ; if ( empty ( $ mids ) ) { return [ ] ; } return $ this -> entityTypeManager -> getStorage ( 'media' ) -> loadMultiple ( $ mids ) ; }
docstring: Gets media that belong to a node.
  
  @param \Drupal\node\NodeInterface $node
  The parent node.
  
  @return \Drupal\media\MediaInterface[]
  The children Media.
  
  @throws \Drupal\Component\Plugin\Exception\PluginNotFoundException
  Calling getStorage() throws if the entity type doesn't exist.
  @throws \Drupal\Component\Plugin\Exception\InvalidPluginDefinitionException
  Calling getStorage() throws if the storage handler couldn't be loaded.
docstring_tokens: Gets media that belong to a node .