Permalink
Browse files

fixed merge issue

  • Loading branch information...
1 parent 847a260 commit 5843f11ed0d46d8666a44286fb56d3dfbedde4e2 @doug-martin committed Jan 13, 2013
Showing with 2 additions and 3 deletions.
  1. +1 −1 extender-min.js
  2. +1 −2 extender.js
View
@@ -1,3 +1,3 @@
/*! extender - v0.0.3 - 2013-01-12
* Copyright (c) 2013 Doug Martin (blog.dougamartin.com); Licensed MIT */
-(function(){function e(e){function i(i){function u(e,r,i){if("function"!=typeof i)throw new TypeError("when extending type you must provide a function");var s;r==="constructor"?s=function(){this._super(arguments),i.apply(this,arguments)}:s=function(){var r=t.call(arguments);r.unshift(this._value);var s=i.apply(this,r);return s!==n?l(s):this},e[r]=s}function a(e,n,r){if("function"!=typeof r)throw new TypeError("when extending type you must provide a function");var i;n==="constructor"?i=function(){this._super(arguments),r.apply(this,arguments)}:i=function(){var n=t.call(arguments);return n.unshift(this._value),r.apply(this,n)},e[n]=i}function f(e,t,n){for(var r in t)t.hasOwnProperty(r)&&(r!=="getters"&&r!=="setters"?r==="noWrap"?f(e,t[r],!0):n?a(e,r,t[r]):u(e,r,t[r]):e[r]=t[r])}function l(e){var t=e,n,i;if(!(e instanceof s)){var u={},a=u.instance={};for(n=0,i=o.length;n<i;n++){var f=o[n];f[0](e)&&r(a,f[1])}t=new(s.extend(u))(e)}return t}function c(){return!0}function h(e,t){if(arguments.length){typeof e=="object"&&(t=e,e=c),t=t||{};var n={};f(n,t),o.push([e,n])}return l}function p(e){e&&e.hasOwnProperty("__defined__")&&(o=o.concat(e.__defined__));for(var t in e)e.hasOwnProperty(t)&&t!=="define"&&t!=="extend"&&t!=="expose"&&(l[t]=e[t]);return l}i=i||[];var s=e({instance:{constructor:function(e){this._value=e},value:function(){return this._value},eq:function(t){return l(this._value===t)},neq:function(t){return l(this._value!==t)},print:function(){return console.log(this._value),this}}}),o=[];return l.define=h,l.extend=p,l.expose=function(){var t;for(var n=0,i=arguments.length;n<i;n++){t=arguments[n];if(typeof t=="object"){for(var s in t)t.hasOwnProperty(s)&&s!=="define"&&s!=="extend"&&s!=="expose"&&(l[n]=t[n]);r(l,arguments[n])}}return l},l.__defined__=o,l}var t=Array.prototype.slice,n,r=function(){function t(e,t){var n,r;for(n in t)if(t.hasOwnProperty(n)){r=t[n];if(!(n in e)||e[n]!==r)e[n]=r}return e}return function(n){n||(n={});for(var r=1,i=arguments.length;r<i;r++)t(n,arguments[r]);return n}}();return{define:function(){return i().define.apply(i,arguments)},extend:function(e){return i().define().extend(e)}}}"undefined"!=typeof exports?"undefined"!=typeof module&&module.exports&&(module.exports=e(require("declare.js"))):"function"==typeof define?define(["require"],function(t){return e(t("declare.js"))}):this.extender=e(this.declare)}).call(this);
+(function(){function e(e){function i(i){function u(e,r,i){if("function"!=typeof i)throw new TypeError("when extending type you must provide a function");var s;r==="constructor"?s=function(){this._super(arguments),i.apply(this,arguments)}:s=function(){var r=t.call(arguments);r.unshift(this._value);var s=i.apply(this,r);return s!==n?l(s):this},e[r]=s}function a(e,n,r){if("function"!=typeof r)throw new TypeError("when extending type you must provide a function");var i;n==="constructor"?i=function(){this._super(arguments),r.apply(this,arguments)}:i=function(){var n=t.call(arguments);return n.unshift(this._value),r.apply(this,n)},e[n]=i}function f(e,t,n){for(var r in t)t.hasOwnProperty(r)&&(r!=="getters"&&r!=="setters"?r==="noWrap"?f(e,t[r],!0):n?a(e,r,t[r]):u(e,r,t[r]):e[r]=t[r])}function l(e){var t=e,n,i;if(!(e instanceof s)){var u={},a=u.instance={};for(n=0,i=o.length;n<i;n++){var f=o[n];f[0](e)&&r(a,f[1])}t=new(s.extend(u))(e)}return t}function c(){return!0}function h(e,t){if(arguments.length){typeof e=="object"&&(t=e,e=c),t=t||{};var n={};f(n,t),o.push([e,n])}return l}function p(e){e&&e.hasOwnProperty("__defined__")&&(o=o.concat(e.__defined__));for(var t in e)e.hasOwnProperty(t)&&t!=="define"&&t!=="extend"&&t!=="expose"&&(l[t]=e[t]);return l}i=i||[];var s=e({instance:{constructor:function(e){this._value=e},value:function(){return this._value},eq:function(t){return l(this._value===t)},neq:function(t){return l(this._value!==t)},print:function(){return console.log(this._value),this}}}),o=[];return l.define=h,l.extend=p,l.expose=function(){var t;for(var n=0,r=arguments.length;n<r;n++){t=arguments[n];if(typeof t=="object")for(var i in t)t.hasOwnProperty(i)&&i!=="define"&&i!=="extend"&&i!=="expose"&&(l[i]=t[i])}return l},l.__defined__=o,l}var t=Array.prototype.slice,n,r=function(){function t(e,t){var n,r;for(n in t)if(t.hasOwnProperty(n)){r=t[n];if(!(n in e)||e[n]!==r)e[n]=r}return e}return function(n){n||(n={});for(var r=1,i=arguments.length;r<i;r++)t(n,arguments[r]);return n}}();return{define:function(){return i().define.apply(i,arguments)},extend:function(e){return i().define().extend(e)}}}"undefined"!=typeof exports?"undefined"!=typeof module&&module.exports&&(module.exports=e(require("declare.js"))):"function"==typeof define?define(["require"],function(t){return e(t("declare.js"))}):this.extender=e(this.declare)}).call(this);
View
@@ -472,10 +472,9 @@
if (typeof methods === "object") {
for (var j in methods) {
if (methods.hasOwnProperty(j) && j !== "define" && j !== "extend" && j !== "expose") {
- _extender[i] = methods[i];
+ _extender[j] = methods[j];
}
}
- merge(_extender, arguments[i]);
}
}
return _extender;

0 comments on commit 5843f11

Please sign in to comment.