title: Fabric.js stage.getActiveObject().clone() vs. fabric.util.object.clone(stage.getActiveObject())
body: <p>I'm using Fabric.js and I'm trying to implement a copy function for images and text element. I found two solutions for on how to copy objects:</p>
  
  <p>Method 1</p>
  
  <pre><code>stage.getActiveObject().clone();
  </code></pre>
  
  <p>Method 2</p>
  
  <pre><code>fabric.util.object.clone(stage.getActiveObject());
  </code></pre>
  
  <p>When using the first method, the cloning won't occur, when using the second method the cloning does occur. To be more specific, for the first method I used the following code:</p>
  
  <pre><code>var obj = stage.getActiveObject();
  if (!obj) return;
  
  var clone = obj.clone();
  clone.set({
      top: clone.get('top') + 30
  });
  stage.add(clone);
  stage.renderAll(); 
  </code></pre>
  
  <p>When running this code on an active object it keeps telling that clone is undefined. Although both methods would do the same thing there must a good reason for using either method 1 or 2. </p>
  
  <p>Could anyone explain the difference between those 2?</p>
  
  <p>Another thing I noticed is that when using the 2nd method, <code>fabric.util.object.clone(stage.getActiveObject());</code> the cloned object gets the same ID as the original object. Although cloning makes a clone of the original I wouldn't make sense to me that they share the same ID. In other words, how can I clone an object and give it a unique ID?</p>