You are here

public function Meta::__construct in Easymeta 8

Construct method.

File

src/Meta.php, line 18

Class

Meta
Meta Class.

Namespace

Drupal\easymeta

Code

public function __construct($language = NULL, $url = NULL) {
  if ($language && $url) {
    $metas = $this
      ->getMetasForUrlAndLanguage($url, $language);
    if ($metas) {
      $this->id = $metas->emid;
      $this->value = $metas->metas;
      $this->url = $url;
      $this->language = $language;
    }
  }
}