summaryrefslogtreecommitdiffstats
path: root/lib/puppet/pgraph.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/puppet/pgraph.rb')
-rw-r--r--lib/puppet/pgraph.rb29
1 files changed, 0 insertions, 29 deletions
diff --git a/lib/puppet/pgraph.rb b/lib/puppet/pgraph.rb
index 71547802e..3bcc2ced0 100644
--- a/lib/puppet/pgraph.rb
+++ b/lib/puppet/pgraph.rb
@@ -19,23 +19,6 @@ class Puppet::PGraph < Puppet::SimpleGraph
super
end
- # Make sure whichever edge has a label keeps the label
- def copy_label(source, target, label)
- # 'require' relationships will not have a label,
- # and all 'subscribe' relationships have the same
- # label, at least for now.
-
- # Labels default to {}, so we can't just test for nil.
- newlabel = label || {}
- oldlabel = edge_label(source, target) || {}
- if ! newlabel.empty? and oldlabel.empty?
- edge_label_set(source, target, label)
- # We should probably check to see if the labels both exist
- # and don't match, but we'd just throw an error which the user
- # couldn't do anyting about.
- end
- end
-
# Which resources a given resource depends upon.
def dependents(resource)
tree_from_vertex(resource).keys
@@ -115,23 +98,11 @@ class Puppet::PGraph < Puppet::SimpleGraph
t = edge.target
end
- # We don't want to add multiple copies of the
- # same edge, but we *do* want to make sure we
- # keep labels around.
- # XXX This will *not* work when we support multiple
- # types of labels, and only works now because
- # you can only do simple subscriptions.
- if edge?(s, t)
- copy_label(s, t, edge.label)
- next
- end
add_edge(s, t, edge.label)
end
# Now get rid of the edge, so remove_vertex! works correctly.
remove_edge!(edge)
- Puppet.debug "%s: %s => %s: %s" % [container,
- edge.source, edge.target, edge?(edge.source, edge.target)]
end
end
remove_vertex!(container)