Jasonette/JASONETTE-iOS

View on GitHub

Showing 198 of 403 total issues

Function utf8ToBytes has 58 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function utf8ToBytes (string, units) {
  units = units || Infinity
  var codePoint
  var length = string.length
  var leadSurrogate = null
Severity: Major
Found in app/Jasonette/rss.js - About 2 hrs to fix

Function _fillout has 56 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    _fillout: function(options) {
      // Given a template and fill it out with passed slot and its corresponding data
      var re = /\{\{(.*?)\}\}/g;
      var full_re = /^\{\{((?!\}\}).)*\}\}$/;
      var variable = options.variable;
Severity: Major
Found in app/Jasonette/st.js - About 2 hrs to fix

Function write has 54 lines of code (exceeds 25 allowed). Consider refactoring.
Open

Buffer.prototype.write = function write (string, offset, length, encoding) {
  // Buffer#write(string)
  if (offset === undefined) {
    encoding = 'utf8'
    length = this.length
Severity: Major
Found in app/Jasonette/rss.js - About 2 hrs to fix

Function formatProperty has 54 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function formatProperty(ctx, value, recurseTimes, visibleKeys, key, array) {
  var name, str, desc;
  desc = Object.getOwnPropertyDescriptor(value, key) || { value: value[key] };
  if (desc.get) {
    if (desc.set) {
Severity: Major
Found in app/Jasonette/rss.js - About 2 hrs to fix

Function pipe has 54 lines of code (exceeds 25 allowed). Consider refactoring.
Open

Stream.prototype.pipe = function(dest, options) {
  var source = this;

  function ondata(chunk) {
    if (dest.writable) {
Severity: Major
Found in app/Jasonette/rss.js - About 2 hrs to fix

Function decode has 53 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    function decode(input) {
        // Don't use UCS-2
        var output = [],
            inputLength = input.length,
            out,
Severity: Major
Found in app/Jasonette/rss.js - About 2 hrs to fix

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

},{}],30:[function(require,module,exports){
// Copyright Joyent, Inc. and other Node contributors.
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the
Severity: Major
Found in app/Jasonette/rss.js - About 2 hrs to fix

Function closeTag has 52 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function closeTag (parser) {
  if (!parser.tagName) {
    strictFail(parser, "Weird empty close tag.")
    parser.textNode += "</>"
    parser.state = S.TEXT
Severity: Major
Found in app/Jasonette/rss.js - About 2 hrs to fix

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

Readable.prototype.read = function(n) {
  var state = this._readableState;
  state.calledRead = true;
  var nOrig = n;
  var ret;
Severity: Major
Found in app/Jasonette/rss.js - About 2 hrs to fix

Function fromList has 48 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function fromList(n, state) {
  var list = state.buffer;
  var length = state.length;
  var stringMode = !!state.decoder;
  var objectMode = !!state.objectMode;
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

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

},{}],29:[function(require,module,exports){
// Copyright Joyent, Inc. and other Node contributors.
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function fromList has 46 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function fromList(n, state) {
  var list = state.buffer;
  var length = state.length;
  var stringMode = !!state.decoder;
  var objectMode = !!state.objectMode;
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

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

},{"./lib/_stream_duplex.js":33}],33:[function(require,module,exports){
// a duplex stream is just a stream that is both readable and writable.
// Since JS doesn't have multiple prototypal inheritance, this class
// prototypally inherits from Readable, and then parasitically from
// Writable.
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function wrap has 45 lines of code (exceeds 25 allowed). Consider refactoring.
Open

Readable.prototype.wrap = function(stream) {
  var state = this._readableState;
  var paused = false;

  var self = this;
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function write has 43 lines of code (exceeds 25 allowed). Consider refactoring.
Open

exports.write = function (buffer, value, offset, isLE, mLen, nBytes) {
  var e, m, c
  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 handleOpenTag has 43 lines of code (exceeds 25 allowed). Consider refactoring.
Open

FeedParser.prototype.handleOpenTag = function (node){
  var n = {};
  n['#name'] = node.name; // Avoid namespace collissions later...
  n['#prefix'] = node.prefix; // The current ns prefix
  n['#local'] = node.local; // The current element name, sans prefix
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function wrap has 43 lines of code (exceeds 25 allowed). Consider refactoring.
Open

Readable.prototype.wrap = function(stream) {
  var state = this._readableState;
  var paused = false;

  var self = this;
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function write has 42 lines of code (exceeds 25 allowed). Consider refactoring.
Open

StringDecoder.prototype.write = function(buffer) {
  var charStr = '';
  // if our last write ended with an incomplete multibyte character
  while (this.charLength) {
    // determine how many remaining bytes this buffer has to offer for this char
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Function format has 42 lines of code (exceeds 25 allowed). Consider refactoring.
Open

Url.prototype.format = function() {
  var auth = this.auth || '';
  if (auth) {
    auth = encodeURIComponent(auth);
    auth = auth.replace(/%3A/i, ':');
Severity: Minor
Found in app/Jasonette/rss.js - About 1 hr to fix

Consider simplifying this complex logical expression.
Open

  } else if (!this.meta.title && // We haven't yet parsed all the metadata
              (node['#name'] === 'channel' ||
               node['#name'] === 'feed' ||
               (node['#local'] === 'channel' && (node['#prefix'] === '' || node['#type'] === 'rdf')) ||
               (node['#local'] === 'feed' && (node['#prefix'] === '' || node['#type'] === 'atom')) ) ) {
Severity: Critical
Found in app/Jasonette/rss.js - About 1 hr to fix
Severity
Category
Status
Source
Language