You are here

public function SqlGroupGraphStorage::getDirectAncestors in Subgroup (Graph) 1.0.x

File

src/Graph/SqlGroupGraphStorage.php, line 513

Class

SqlGroupGraphStorage
SQL based storage of the group relationship graph.

Namespace

Drupal\ggroup\Graph

Code

public function getDirectAncestors($group_id) {
  $this
    ->loadMap($group_id);
  return isset($this->directAncestors[$group_id]) ? $this->directAncestors[$group_id] : [];
}