Possible bug with undelegate & clone

Possible bug with undelegate & clone

  1. var newNode = node.clone(true);
  2. newNode
  3.       .children(".sibling").undelegate().end()
  4.       .children(".wrap,.group").css("display","block");
  5. inlay.append(newNode);

I've tried this in a dozen ways now, both with append, appendTo and in different orders, but the outcome is the same: undelegate never removes the click function.
Any idea why this code would not work or is this really a bug?

Further testing with the exaples on http://api.jquery.com/undelegate/ reveals:
  1. $("body").undelegate();
works just fine, while
  1. $("button").undelegate();
  2. $("#theone").undelegate();
just don't do anything. Too bad I can't use the body selector in my nested, recursive application.