build/canadarm.js
function findStackData(stack) {
    // If the stack is not in the error we cannot get any information and
    // should return immediately.
    if (stack === undefined || stack === null) {
      return {
        'url': Canadarm.constant.UNKNOWN_LOG,
        'lineNumber': Canadarm.constant.UNKNOWN_LOG,
        'columnNumber': Canadarm.constant.UNKNOWN_LOG
      };
    }

    // Remove the newlines from all browsers so we can regex this easier
    var stackBits = stack.replace(/(\r\n|\n|\r)/gm,'').match(STACK_SCRIPT_COLUMN_LINE_FINDER),
      newStack, stackData = [],
      stackHasBits = (stackBits !== null && stackBits !== undefined);

    while (stackHasBits) {
      stackBits = stackBits[1].match(STACK_SCRIPT_COLUMN_LINE_FINDER);
      newStack = stackBits !== null ? stackBits[1] : null;
      stackData = stackBits !== null ? stackBits : stackData;
      stackHasBits = (stackBits !== null && stackBits !== undefined);
    }

    return {
      'url': stackData.length >= 1 ? stackData[1] : Canadarm.constant.UNKNOWN_LOG,
      'lineNumber': stackData.length >= 1 ? stackData[2] : Canadarm.constant.UNKNOWN_LOG,
      'columnNumber': stackData.length >= 1 ? stackData[3] : Canadarm.constant.UNKNOWN_LOG
    };
  }
function findStackData(stack) {
    // If the stack is not in the error we cannot get any information and
    // should return immediately.
    if (stack === undefined || stack === null) {
      return {
        'url': Canadarm.constant.UNKNOWN_LOG,
        'lineNumber': Canadarm.constant.UNKNOWN_LOG,
        'columnNumber': Canadarm.constant.UNKNOWN_LOG
      };
    }

    // Remove the newlines from all browsers so we can regex this easier
    var stackBits = stack.replace(/(\r\n|\n|\r)/gm,'').match(STACK_SCRIPT_COLUMN_LINE_FINDER),
      newStack, stackData = [],
      stackHasBits = (stackBits !== null && stackBits !== undefined);

    while (stackHasBits) {
      stackBits = stackBits[1].match(STACK_SCRIPT_COLUMN_LINE_FINDER);
      newStack = stackBits !== null ? stackBits[1] : null;
      stackData = stackBits !== null ? stackBits : stackData;
      stackHasBits = (stackBits !== null && stackBits !== undefined);
    }

    return {
      'url': stackData.length >= 1 ? stackData[1] : Canadarm.constant.UNKNOWN_LOG,
      'lineNumber': stackData.length >= 1 ? stackData[2] : Canadarm.constant.UNKNOWN_LOG,
      'columnNumber': stackData.length >= 1 ? stackData[3] : Canadarm.constant.UNKNOWN_LOG
    };
  }
function findStackData ( stack ) { // If the stack is not in the error we cannot get any information and // should return immediately. if ( stack === undefined || stack === null ) { return { 'url' : Canadarm . constant . UNKNOWN_LOG , 'lineNumber' : Canadarm . constant . UNKNOWN_LOG , 'columnNumber' : Canadarm . constant . UNKNOWN_LOG } ; } // Remove the newlines from all browsers so we can regex this easier var stackBits = stack . replace ( / (\r\n|\n|\r) / gm , '' ) . match ( STACK_SCRIPT_COLUMN_LINE_FINDER ) , newStack , stackData = [ ] , stackHasBits = ( stackBits !== null && stackBits !== undefined ) ; while ( stackHasBits ) { stackBits = stackBits [ 1 ] . match ( STACK_SCRIPT_COLUMN_LINE_FINDER ) ; newStack = stackBits !== null ? stackBits [ 1 ] : null ; stackData = stackBits !== null ? stackBits : stackData ; stackHasBits = ( stackBits !== null && stackBits !== undefined ) ; } return { 'url' : stackData . length >= 1 ? stackData [ 1 ] : Canadarm . constant . UNKNOWN_LOG , 'lineNumber' : stackData . length >= 1 ? stackData [ 2 ] : Canadarm . constant . UNKNOWN_LOG , 'columnNumber' : stackData . length >= 1 ? stackData [ 3 ] : Canadarm . constant . UNKNOWN_LOG } ; }
Generates the url, lineNumber, and Column number of the error.
Generates the url lineNumber and Column number of the error .