Jasonette/JASONETTE-iOS

View on GitHub

Showing 198 of 403 total issues

Function addListener has 33 lines of code (exceeds 25 allowed). Consider refactoring.
Open

EventEmitter.prototype.addListener = function(type, listener) {
  var m;

  if (!isFunction(listener))
    throw TypeError('listener must be a function');
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function ReadableState has 33 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function ReadableState(options, stream) {
  Duplex = Duplex || require('./_stream_duplex');

  options = options || {};

Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function handleAttributes has 32 lines of code (exceeds 25 allowed). Consider refactoring.
Open

FeedParser.prototype.handleAttributes = function handleAttributes (attrs, el) {
  /*
   * Using the sax.js option { xmlns: true }
   * attrs is an array of objects (not strings) having the following properties
   * name - e.g., xmlns:dc or href
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function readableAddChunk has 32 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function readableAddChunk(stream, state, chunk, encoding, addToFront) {
  var er = chunkInvalid(state, chunk);
  if (er) {
    stream.emit('error', er);
  } else if (chunk === null || chunk === undefined) {
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function indexOf has 32 lines of code (exceeds 25 allowed). Consider refactoring.
Open

Buffer.prototype.indexOf = function indexOf (val, byteOffset) {
  if (byteOffset > 0x7fffffff) byteOffset = 0x7fffffff
  else if (byteOffset < -0x80000000) byteOffset = -0x80000000
  byteOffset >>= 0

Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function WritableState has 31 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function WritableState(options, stream) {
  Duplex = Duplex || require('./_stream_duplex');

  options = options || {};

Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function 2 has 31 lines of code (exceeds 25 allowed). Consider refactoring.
Open

},{"./utils":16,"addressparser":3,"array-indexofobject":4,"readable-stream":14,"sax":15,"util":50}],2:[function(require,module,exports){
/*
 * Default namespaces
 *
 * Lookup by URI
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function slowToString has 31 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function slowToString (encoding, start, end) {
  var loweredCase = false

  start = start | 0
  end = end === undefined || end === Infinity ? this.length : end | 0
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function ReadableState has 30 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function ReadableState(options, stream) {
  options = options || {};

  // the point at which it stops calling _read() to fill the buffer
  // Note: 0 is a valid value, means "don't call _read preemptively ever"
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function select has 30 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    select: function(obj, filter, serialized) {
      // iterate '$selected'
      //
      /*
      SELECT.$selected = [{
Severity: Minor
Found in app/Jasonette/st.js - About 1 hr to fix

Function byteLength has 29 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function byteLength (string, encoding) {
  if (typeof string !== 'string') string = '' + string

  var len = string.length
  if (len === 0) return 0
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function slice has 29 lines of code (exceeds 25 allowed). Consider refactoring.
Open

Buffer.prototype.slice = function slice (start, end) {
  var len = this.length
  start = ~~start
  end = end === undefined ? len : ~~end

Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function SAXStream has 28 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function SAXStream (strict, opt) {
  if (!(this instanceof SAXStream)) return new SAXStream(strict, opt)

  Stream.apply(this)

Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function removeAllListeners has 28 lines of code (exceeds 25 allowed). Consider refactoring.
Open

EventEmitter.prototype.removeAllListeners = function(type) {
  var key, listeners;

  if (!this._events)
    return this;
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function resolveLevel has 27 lines of code (exceeds 25 allowed). Consider refactoring.
Open

  function resolveLevel (level) {
    var els = Object.keys(level);
    els.forEach(function(el){
      if (Array.isArray(level[el])) {
        level[el].forEach(resolveLevel);
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function read has 26 lines of code (exceeds 25 allowed). Consider refactoring.
Open

exports.read = function (buffer, offset, isLE, mLen, nBytes) {
  var e, m
  var eLen = nBytes * 8 - mLen - 1
  var eMax = (1 << eLen) - 1
  var eBias = eMax >> 1
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function fillout has 26 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    fillout: function(data, template, raw) {
      // 1. fill out if possible
      // 2. otherwise return the original
      var replaced = template;
      // Run fillout() only if it's a template. Otherwise just return the original string
Severity: Minor
Found in app/Jasonette/st.js - About 1 hr to fix

Function parseEntity has 26 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function parseEntity (parser) {
  var entity = parser.entity
    , entityLC = entity.toLowerCase()
    , num
    , numStr = ""
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Consider simplifying this complex logical expression.
Open

  if (!hostlessProtocol[proto] &&
      (slashes || (proto && !slashedProtocol[proto]))) {

    // there's a hostname.
    // the first instance of /, ?, ;, or # ends the host.
Severity: Major
Found in app/Jasonette/rss.js - About 1 hr to fix

Function doWrite has 7 arguments (exceeds 4 allowed). Consider refactoring.
Open

function doWrite(stream, state, writev, len, chunk, encoding, cb) {
Severity: Major
Found in app/Jasonette/rss.js - About 50 mins to fix
Severity
Category
Status
Source
Language