mirror of
https://github.com/Hopiu/angular.js.git
synced 2026-03-17 07:40:22 +00:00
clean up error reporting
This commit is contained in:
parent
719f6e15a0
commit
b5bbfaeb80
1 changed files with 1 additions and 17 deletions
|
|
@ -3,8 +3,6 @@
|
|||
if (typeof document.getAttribute == 'undefined')
|
||||
document.getAttribute = function() {};
|
||||
|
||||
if (!window['console']) window['console']={'log':noop, 'error':noop};
|
||||
|
||||
var consoleNode,
|
||||
PRIORITY_FIRST = -99999,
|
||||
PRIORITY_WATCH = -1000,
|
||||
|
|
@ -18,6 +16,7 @@ var consoleNode,
|
|||
msie = !!/(msie) ([\w.]+)/.exec(lowercase(navigator.userAgent)),
|
||||
jqLite = jQuery || jqLiteWrap,
|
||||
slice = Array.prototype.slice,
|
||||
error = window['console'] ? bind(window['console'], window['console']['error']) : noop,
|
||||
angular = window['angular'] || (window['angular'] = {}),
|
||||
angularTextMarkup = extensionMap(angular, 'textMarkup'),
|
||||
angularAttrMarkup = extensionMap(angular, 'attrMarkup'),
|
||||
|
|
@ -174,21 +173,6 @@ function indexOf(array, obj) {
|
|||
return -1;
|
||||
}
|
||||
|
||||
function error(a, b, c){
|
||||
var console = window['console'];
|
||||
switch(arguments.length) {
|
||||
case 1:
|
||||
console['error'](a);
|
||||
break;
|
||||
case 2:
|
||||
console['error'](a, b);
|
||||
break;
|
||||
default:
|
||||
console['error'](a, b, c);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
function isLeafNode (node) {
|
||||
if (node) {
|
||||
switch (node.nodeName) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue