improvements and bugfixes to FullCalendar's MomentJS extensions

notably we have no side effects on the Moment prototype anymore. we subclass
This commit is contained in:
Adam Shaw
2014-02-02 21:56:02 -08:00
parent 80fe8c1c96
commit edcd275c91
3 changed files with 107 additions and 68 deletions
+4 -1
View File
@@ -3,12 +3,15 @@ fc.applyAll = applyAll;
function createObject(proto) { // like Object.create
// Create an object that has the given prototype.
// Just like Object.create
function createObject(proto) {
var f = function() {};
f.prototype = proto;
return new f();
}
// copy specifically-owned (non-protoype) properties of `b` onto `a`
function extend(a, b) {
for (var i in b) {
if (b.hasOwnProperty(i)) {