mbrowne/simpleoo.js — pull request #2 by justinmc (2013-10-26 09:11:16+00:00)
Title: modified deepCopy to prevent infinite loops in cyclic references

Here's the pull request for issue 1 (https://github.com/mbrowne/simpleoo.js/issues/1). It seems to work fine with the "visited objects" array. This adds space and time complexity for large objects, but considering what people actually would use this for, I think it should be fine...

Check out my code and make sure it looks how you want it. I also added a test in test.html.