Skip to content

Commit b5bbfae

Browse files
committed
clean up error reporting
1 parent 719f6e1 commit b5bbfae

1 file changed

Lines changed: 1 addition & 17 deletions

File tree

src/Angular.js

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33
if (typeof document.getAttribute == 'undefined')
44
document.getAttribute = function() {};
55

6-
if (!window['console']) window['console']={'log':noop, 'error':noop};
7-
86
var consoleNode,
97
PRIORITY_FIRST = -99999,
108
PRIORITY_WATCH = -1000,
@@ -18,6 +16,7 @@ var consoleNode,
1816
msie = !!/(msie) ([\w.]+)/.exec(lowercase(navigator.userAgent)),
1917
jqLite = jQuery || jqLiteWrap,
2018
slice = Array.prototype.slice,
19+
error = window['console'] ? bind(window['console'], window['console']['error']) : noop,
2120
angular = window['angular'] || (window['angular'] = {}),
2221
angularTextMarkup = extensionMap(angular, 'textMarkup'),
2322
angularAttrMarkup = extensionMap(angular, 'attrMarkup'),
@@ -174,21 +173,6 @@ function indexOf(array, obj) {
174173
return -1;
175174
}
176175

177-
function error(a, b, c){
178-
var console = window['console'];
179-
switch(arguments.length) {
180-
case 1:
181-
console['error'](a);
182-
break;
183-
case 2:
184-
console['error'](a, b);
185-
break;
186-
default:
187-
console['error'](a, b, c);
188-
break;
189-
}
190-
}
191-
192176
function isLeafNode (node) {
193177
if (node) {
194178
switch (node.nodeName) {

0 commit comments

Comments
 (0)