@rasmusfl0e - Why is this considered very hackable? I believe your assuming "protected" and not "private". Besides, isn't all javascript very hackable ;-)
@Ryan - I went ahead and updated the Mutator to fix your exploit. Posted here: http://www.nwhite.net/2008/10/10/private-methods-with-mootools-update2/ On Sun, Oct 12, 2008 at 7:42 PM, rasmusfl0e <[EMAIL PROTECTED]> wrote: > > it's very hackable: > > Secret.implement({ > set: function(message){ > secret = message; > } > }); > msg.set("hello, world"); > msg.get(); // returns "hello, world" > > On Oct 10, 10:47 pm, "Nathan White" <[EMAIL PROTECTED]> wrote: > > ok. I have made two updates to my Privates Mutator. > > > > Now if you pass in functions into the privates object a bind is created > to > > the class. > > > > http://www.nwhite.net/2008/10/10/private-methods-with-mootools-update2/ > > > > an example is provided. >
