plainblack/Lacuna-Web-Client

View on GitHub

Showing 509 of 1,320 total issues

Function build has 189 lines of code (exceeds 25 allowed). Consider refactoring.
Open

        build: _.once(function() {
            this.createEvent("onRpc");
            this.id = "profile";

            var container = document.createElement("div");
Severity: Major
Found in app/js-yui/profile.js - About 7 hrs to fix

    File mercenariesGuild.js has 464 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    YAHOO.namespace("lacuna.buildings");
    
    if (typeof YAHOO.lacuna.buildings.MercenariesGuild == "undefined" || !YAHOO.lacuna.buildings.MercenariesGuild) {
        
    (function(){
    Severity: Minor
    Found in app/js-yui/building/mercenariesGuild.js - About 7 hrs to fix

      Function EmpireStats has 175 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      EmpireStats : function(){
                        if(this.EmpireTable) {
                            this.EmpireTable.requery();
                        }
                        else {
      Severity: Major
      Found in app/js-yui/stats.js - About 7 hrs to fix

        Function AllianceStats has 173 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

                AllianceStats : function(){
                    if(this.AllianceTable) {
                        this.AllianceTable.requery();
                    }
                    else {
        Severity: Major
        Found in app/js-yui/stats.js - About 6 hrs to fix

          File building.js has 417 lines of code (exceeds 250 allowed). Consider refactoring.
          Open

          YAHOO.namespace("lacuna.buildings");
          
          var BodyRPCStore = require('js/stores/rpc/body');
          
          if (typeof YAHOO.lacuna.buildings.Building == "undefined" || !YAHOO.lacuna.buildings.Building) {
          Severity: Minor
          Found in app/js-yui/building.js - About 6 hrs to fix

            Consider simplifying this complex logical expression.
            Open

            if (typeof YAHOO.lacuna.SpeciesDesigner == "undefined" || !YAHOO.lacuna.SpeciesDesigner) {
            
            (function(){
                var Util = YAHOO.util,
                    Dom = Util.Dom,
            Severity: Critical
            Found in app/js-yui/speciesDesigner.js - About 6 hrs to fix

              Function ShowPlanet has 149 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                      ShowPlanet : function(tile, keepOpen) {
                          if(!keepOpen) {
                              Game.OverlayManager.hideAllBut(this.planetDetails.id);
                          }
                          var panel = this.planetDetails;
              Severity: Major
              Found in app/js-yui/mapStar.js - About 5 hrs to fix

                Function render has 148 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    render : function() {
                        var b    = this.props.building;
                        var body = this.props.body;
                
                        // Don't let the user downgrade a level 1 building. They shoulod demolish it instead.
                Severity: Major
                Found in app/js/components/window/building/productionTab.jsx - About 5 hrs to fix

                  Function SpyInfo has 145 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                          SpyInfo : function(spy) {
                              var assign = spy.possible_assignments,
                                  div = document.createElement("div"),
                                  ul = document.createElement("ul"),
                                  li = document.createElement("li"),
                  Severity: Major
                  Found in app/js-yui/building/intelligence.js - About 5 hrs to fix

                    File blackHoleGenerator.js has 395 lines of code (exceeds 250 allowed). Consider refactoring.
                    Open

                    YAHOO.namespace("lacuna.buildings");
                    
                    if (typeof YAHOO.lacuna.buildings.BlackHoleGenerator == "undefined" ||
                               !YAHOO.lacuna.buildings.BlackHoleGenerator) {
                    
                    
                    Severity: Minor
                    Found in app/js-yui/building/blackHoleGenerator.js - About 5 hrs to fix

                      Function _buildPanel has 135 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                              _buildPanel : _.once(function() {
                                  var panelId = "messagingPanel";
                                  var panel = document.createElement("div");
                                  panel.id = panelId;
                                  panel.innerHTML = ['<div class="hd">Messaging</div>',
                      Severity: Major
                      Found in app/js-yui/messaging.js - About 5 hrs to fix

                        Function success has 132 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                                            success : function(o){
                                                YAHOO.log(o, "info", "ShowPlanet.get_status.success");
                        
                                    var body = o.result.body,
                                        tab, tabs,
                        Severity: Major
                        Found in app/js-yui/mapStar.js - About 5 hrs to fix

                          File login.js has 386 lines of code (exceeds 250 allowed). Consider refactoring.
                          Open

                          'use strict';
                          
                          var UserActions = require('js/actions/user');
                          var Fingerprint2 = require('fingerprintjs2');
                          
                          
                          Severity: Minor
                          Found in app/js-yui/login.js - About 5 hrs to fix

                            Function Transporter has 130 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                                var Transporter = function(result){
                                    Transporter.superclass.constructor.call(this, result);
                            
                                    this.transport = result.transport;
                                    this.service = Game.Services.Buildings.Transporter;
                            Severity: Major
                            Found in app/js-yui/building/transporter.js - About 5 hrs to fix

                              Function Trade has 128 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                  var Trade = function(result){
                                      Trade.superclass.constructor.call(this, result);
                                      
                                      this.transport = result.transport;
                                      this.service = Game.Services.Buildings.Trade;
                              Severity: Major
                              Found in app/js-yui/building/tradeMinistry.js - About 5 hrs to fix

                                Function updateDisplay has 128 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                            this.buildingBuilder.updateDisplay = function() {
                                                var mainTag = this.mainTag;
                                                var subTag = this.subTag;
                                                var b = this.buildable[mainTag] || this.buildable[subTag];
                                                var list = this.buildingList;
                                Severity: Major
                                Found in app/js-yui/mapPlanet.js - About 5 hrs to fix

                                  File library.js has 365 lines of code (exceeds 250 allowed). Consider refactoring.
                                  Open

                                  /*
                                  Public Key:
                                  53137d8f-3544-4118-9001-b0acbec70b3d
                                  Private Key:
                                  d07c9bd4-fcb7-427f-9064-218064677fef
                                  Severity: Minor
                                  Found in app/js-yui/library.js - About 4 hrs to fix

                                    File miningMinistry.js has 363 lines of code (exceeds 250 allowed). Consider refactoring.
                                    Open

                                    YAHOO.namespace("lacuna.buildings");
                                    
                                    if (typeof YAHOO.lacuna.buildings.MiningMinistry == "undefined" || !YAHOO.lacuna.buildings.MiningMinistry) {
                                        
                                    (function(){
                                    Severity: Minor
                                    Found in app/js-yui/building/miningMinistry.js - About 4 hrs to fix

                                      Function handleUpdate has 116 lines of code (exceeds 25 allowed). Consider refactoring.
                                      Open

                                              handleUpdate : function() {
                                                  var updatesLeft = 1;
                                                  if (this.new_password.value != "") {
                                                      if (this.new_password.value != this.confirm_password.value) {
                                                          alert("Passwords don't match!");
                                      Severity: Major
                                      Found in app/js-yui/profile.js - About 4 hrs to fix

                                        Function render has 111 lines of code (exceeds 25 allowed). Consider refactoring.
                                        Open

                                            render : function() {
                                        
                                                return (
                                                    <div className="ui left vertical inverted sidebar menu" ref="sidebar">
                                        
                                        
                                        Severity: Major
                                        Found in app/js/components/menu/leftSidebar.jsx - About 4 hrs to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language