Javascript Constant Setting Variable
<p>When running this code, the whatever value is first passed in with the constructor <code>Test(callbacks)</code> becomes the callback that is always called, even in later instantiations of <code>Test</code></p>

<pre><code>function Test(callbacks) {
    if (callbacks) {
        if (callbacks.callback) {
            this.callback = callbacks.callback;
        }
    }

    this.options.complete = $.proxy(this.options.complete, this);
}

Test.prototype = {
    options: {
        type: "GET",
        complete: function() {
            this.callback();
        }
    },
    callback: function() { console.log("OVERRIDE ME"); },

    execute: function() {
        $.ajax(this.options);
    }
};

var eins = {callback: function() {console.log("AAA");}};
var zwei = {callback: function() {console.log("BBB");}};

var A = new Test(eins);
var B = new Test(zwei);

A.execute();
B.execute();
</code></pre>

<p>Running this code, every time you will get the output <code>AAA</code>. How does <code>function() {console.log("AAA");}</code> become a constant value for the prototype?</p>
