Fix Function.prototype and also configure chaining