diff --git a/app/Util/DependencyGraph.php b/app/Util/DependencyGraph.php index f88e24d..f675467 100644 --- a/app/Util/DependencyGraph.php +++ b/app/Util/DependencyGraph.php @@ -105,6 +105,11 @@ class DependencyGraph } } + if (sizeof($state) == 0) + { + throw new \Exception('Cannot solve dependency graph -- no edge nodes. Circular dependency?'); + } + // Then walk through the array and insert each node's dependencies before // it recursively. $iter = 0;