HerbCSO/ticketeer

View on GitHub

Showing 181 of 292 total issues

Function _pathToRelative has 77 lines of code (exceeds 25 allowed). Consider refactoring.
Open

        pathToRelative = R._pathToRelative = function (pathArray) {
            var pth = paths(pathArray);
            if (pth.rel) {
                return pathClone(pth.rel);
            }
Severity: Major
Found in app/assets/javascripts/raphael.js - About 3 hrs to fix

    Function getRGB has 69 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        R.getRGB = cacher(function (colour) {
            if (!colour || !!((colour = Str(colour)).indexOf("-") + 1)) {
                return {r: -1, g: -1, b: -1, hex: "none", error: 1, toString: clrToString};
            }
            if (colour == "none") {
    Severity: Major
    Found in app/assets/javascripts/raphael.js - About 2 hrs to fix

      Consider simplifying this complex logical expression.
      Open

              if (res.type == "text") {
                  res.paper.canvas.style.display = E;
                  var span = res.paper.span,
                      m = 100,
                      fontSize = a.font && a.font.match(/\d+(?:\.\d*)?(?=px)/);
      Severity: Critical
      Found in app/assets/javascripts/raphael.js - About 2 hrs to fix

        Function attr has 60 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            elproto.attr = function (name, value) {
                if (this.removed) {
                    return this;
                }
                if (name == null) {
        Severity: Major
        Found in app/assets/javascripts/raphael.js - About 2 hrs to fix

          Function eve has 59 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

                  eve = function (name, scope) {
                      name = String(name);
                      var e = events,
                          oldstop = stop,
                          args = Array.prototype.slice.call(arguments, 2),
          Severity: Major
          Found in app/assets/javascripts/raphael.js - About 2 hrs to fix

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

                elproto.attr = function (name, value) {
                    if (this.removed) {
                        return this;
                    }
                    if (name == null) {
            Severity: Major
            Found in app/assets/javascripts/raphael.js - About 2 hrs to fix

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

                    this.data = (function() {
                      var _i, _len, _results;
                      _results = [];
                      for (index = _i = 0, _len = data.length; _i < _len; index = ++_i) {
                        row = data[index];
              Severity: Major
              Found in app/assets/javascripts/morris.js - About 2 hrs to fix

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

                    eve.off = eve.unbind = function (name, f) {
                        if (!name) {
                            eve._events = events = {n: {}};
                            return;
                        }
                Severity: Major
                Found in app/assets/javascripts/raphael.js - About 2 hrs to fix

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

                                  processPath = function (path, d, pcom) {
                                      var nx, ny;
                                      if (!path) {
                                          return ["C", d.x, d.y, d.x, d.y, d.x, d.y];
                                      }
                  Severity: Major
                  Found in app/assets/javascripts/raphael.js - About 2 hrs to fix

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

                      Morris.parseDate = function(date) {
                        var isecs, m, msecs, n, o, offsetmins, p, q, r, ret, secs;
                        if (typeof date === 'number') {
                          return date;
                        }
                    Severity: Major
                    Found in app/assets/javascripts/morris.js - About 2 hrs to fix

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

                          addGradientFill = function (o, gradient, fill) {
                              o.attrs = o.attrs || {};
                              var attrs = o.attrs,
                                  pow = Math.pow,
                                  opacity,
                      Severity: Major
                      Found in app/assets/javascripts/raphael.js - About 2 hrs to fix

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

                            function interHelper(bez1, bez2, justCount) {
                                var bbox1 = R.bezierBBox(bez1),
                                    bbox2 = R.bezierBBox(bez2);
                                if (!R.isBBoxIntersect(bbox1, bbox2)) {
                                    return justCount ? 0 : [];
                        Severity: Major
                        Found in app/assets/javascripts/raphael.js - About 2 hrs to fix

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

                              Donut.prototype.redraw = function() {
                                var C, cx, cy, i, idx, last, max_value, min, next, seg, total, value, w, _i, _j, _k, _len, _len1, _len2, _ref, _ref1, _ref2, _results;
                                this.el.empty();
                                this.raphael = new Raphael(this.el[0]);
                                cx = this.el.width() / 2;
                          Severity: Major
                          Found in app/assets/javascripts/morris.js - About 2 hrs to fix

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

                                Line.prototype.drawXAxis = function() {
                                  var drawLabel, l, labels, prevAngleMargin, prevLabelMargin, row, ypos, _i, _len, _results,
                                    _this = this;
                                  ypos = this.bottom + this.options.padding / 2;
                                  prevLabelMargin = null;
                            Severity: Major
                            Found in app/assets/javascripts/morris.js - About 2 hrs to fix

                              Function interPathHelper has 51 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                  function interPathHelper(path1, path2, justCount) {
                                      path1 = R._path2curve(path1);
                                      path2 = R._path2curve(path2);
                                      var x1, y1, x2, y2, x1m, y1m, x2m, y2m, bez1, bez2,
                                          res = justCount ? 0 : [];
                              Severity: Major
                              Found in app/assets/javascripts/raphael.js - About 2 hrs to fix

                                Function addEvent has 51 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                    addEvent = (function () {
                                        if (g.doc.addEventListener) {
                                            return function (obj, type, fn, element) {
                                                var f = function (e) {
                                                    var pos = getEventPosition(e);
                                Severity: Major
                                Found in app/assets/javascripts/raphael.js - About 2 hrs to fix

                                  Consider simplifying this complex logical expression.
                                  Open

                                              if (params[has](att)) {
                                                  if (!R._availableAttrs[has](att)) {
                                                      continue;
                                                  }
                                                  var value = params[att];
                                  Severity: Critical
                                  Found in app/assets/javascripts/raphael.js - About 2 hrs to fix

                                    Function CubicBezierAtTime has 50 lines of code (exceeds 25 allowed). Consider refactoring.
                                    Open

                                        function CubicBezierAtTime(t, p1x, p1y, p2x, p2y, duration) {
                                            var cx = 3 * p1x,
                                                bx = 3 * (p2x - p1x) - cx,
                                                ax = 1 - cx - bx,
                                                cy = 3 * p1y,
                                    Severity: Minor
                                    Found in app/assets/javascripts/raphael.js - About 2 hrs to fix

                                      Function Hover has 50 lines of code (exceeds 25 allowed). Consider refactoring.
                                      Open

                                        Morris.Hover = (function() {
                                      
                                          Hover.defaults = {
                                            "class": 'morris-hover morris-default-style'
                                          };
                                      Severity: Minor
                                      Found in app/assets/javascripts/morris.js - About 2 hrs to fix

                                        Function Grid has 47 lines of code (exceeds 25 allowed). Consider refactoring.
                                        Open

                                            function Grid(options) {
                                              var _this = this;
                                              if (typeof options.element === 'string') {
                                                this.el = $(document.getElementById(options.element));
                                              } else {
                                        Severity: Minor
                                        Found in app/assets/javascripts/morris.js - About 1 hr to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language