diff --git a/lib/codemirror.js b/lib/codemirror.js
index 542fb417320d588443ee00124492c72f40432def..20c7329c7edebeca4b034ab3ecb7c2aee8238ecc 100644
--- a/lib/codemirror.js
+++ b/lib/codemirror.js
@@ -7467,13 +7467,11 @@
       if (array[i] == elt) return i;
     return -1;
   }
-  if ([].indexOf) indexOf = function(array, elt) { return array.indexOf(elt); };
   function map(array, f) {
     var out = [];
     for (var i = 0; i < array.length; i++) out[i] = f(array[i], i);
     return out;
   }
-  if ([].map) map = function(array, f) { return array.map(f); };
 
   function createObj(base, props) {
     var inst;