jkuchar/MultipleFileUpload

View on GitHub

Showing 205 of 353 total issues

Function XMLHttpRequest has 164 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    function XMLHttpRequest() {
        var _status, _response, _iframe;

        function cleanup(cb) {
            var target = this, uid, form, inputs, i, hasFile = false;
Severity: Major
Found in public/plupload/js/moxie.js - About 6 hrs to fix

    Function _initUploader has 162 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        _initUploader: function() {
            var self = this
            , id = this.id
            , uploader
            , options = { 
    Severity: Major
    Found in public/plupload/js/jquery.ui.plupload/jquery.ui.plupload.js - About 6 hrs to fix

      Function FileInput has 152 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          function FileInput() {
              var _uid, _files = [], _mimes = [], _options;
      
              function addInput() {
                  var comp = this, I = comp.getRuntime(), shimContainer, browseButton, currForm, form, input, uid;
      Severity: Major
      Found in public/plupload/js/moxie.js - About 6 hrs to fix

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

                init : function(options, swfUploadOptions) {
                    
                    return this.each(function() {
        
                        // Create a reference to the jQuery DOM object
        Severity: Major
        Found in public/uploadify/js/jquery.uploadify-3.1.js - About 5 hrs to fix

          Function Runtime has 146 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              function Runtime(options, type, caps, modeCaps, preferredMode) {
                  /**
                  Dispatched when runtime is initialized and ready.
                  Results in RuntimeInit on a connected component.
          
          
          Severity: Major
          Found in public/plupload/js/moxie.js - About 5 hrs to fix

            Function onUploadFile has 146 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                function onUploadFile(up, file) {
                    var url = up.settings.url
                    , chunkSize = up.settings.chunk_size
                    , retries = up.settings.max_retries
                    , features = up.features
            Severity: Major
            Found in public/plupload/js/plupload.dev.js - About 5 hrs to fix

              Function EventTarget has 137 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  function EventTarget() {
                      // hash of event listeners by object uid
                      var eventpool = {};
                              
                      Basic.extend(this, {
              Severity: Major
              Found in public/plupload/js/moxie.js - About 5 hrs to fix

                Function FlashRuntime has 137 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    function FlashRuntime(options) {
                        var I = this, initTimer;
                
                        options = Basic.extend({ swf_url: Env.swf_url }, options);
                
                
                Severity: Major
                Found in public/plupload/js/moxie.js - About 5 hrs to fix

                  Function formatUnits has a Cognitive Complexity of 36 (exceeds 5 allowed). Consider refactoring.
                  Open

                      SWFUpload.speed.formatUnits = function (baseNumber, unitDivisors, unitLabels, singleFractional) {
                          var i, unit, unitDivisor, unitLabel;
                  
                          if (baseNumber === 0) {
                              return "0 " + unitLabels[unitLabels.length - 1];
                  Severity: Minor
                  Found in public/swfupload/js/swfupload.speed.js - About 5 hrs to fix

                  Cognitive Complexity

                  Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                  A method's cognitive complexity is based on a few simple rules:

                  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                  • Code is considered more complex for each "break in the linear flow of the code"
                  • Code is considered more complex when "flow breaking structures are nested"

                  Further reading

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

                      function FileDrop() {
                          var _files = [], _allowedExts = [], _options;
                  
                          Basic.extend(this, {
                              init: function(options) {
                  Severity: Major
                  Found in public/plupload/js/moxie.js - About 5 hrs to fix

                    Function send has 120 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                                send: function(meta, data) {
                                    var target = this
                                    , isGecko2_5_6 = (Env.browser === 'Mozilla' && Env.version >= 4 && Env.version < 7)
                                    , isAndroidBrowser = Env.browser === 'Android Browser'
                                    , mustSendAsBinary = false
                    Severity: Major
                    Found in public/plupload/js/moxie.js - About 4 hrs to fix

                      Function setOption has 113 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                          function setOption(option, value, init) {
                              var self = this, reinitRequired = false;
                      
                              function _setOption(option, value, init) {
                                  var oldValue = settings[option];
                      Severity: Major
                      Found in public/plupload/js/plupload.dev.js - About 4 hrs to fix

                        Function _doXHR has 109 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                                function _doXHR(data) {
                                    var self = this;
                                    
                                    _start_time = new Date().getTime();
                        
                        
                        Severity: Major
                        Found in public/plupload/js/moxie.js - About 4 hrs to fix

                          Function uploadNextChunk has 109 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                                  function uploadNextChunk() {
                                      var chunkBlob, formData, args = {}, curChunkSize;
                          
                                      // make sure that file wasn't cancelled and upload is not stopped in general
                                      if (file.status !== plupload.UPLOADING || up.state === plupload.STOPPED) {
                          Severity: Major
                          Found in public/plupload/js/plupload.dev.js - About 4 hrs to fix

                            Function FileInput has 107 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                                function FileInput(options) {
                                    var self = this,
                                        container, browseButton, defaults;
                            
                                    // if flat argument passed it should be browse_button id
                            Severity: Major
                            Found in public/plupload/js/moxie.js - About 4 hrs to fix

                              Function FileInput has 99 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                  function FileInput() {
                                      var _files = [], _options;
                              
                                      Basic.extend(this, {
                                          init: function(options) {
                              Severity: Major
                              Found in public/plupload/js/moxie.js - About 3 hrs to fix

                                Method handleUploads has 98 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                    public function handleUploads()
                                    {
                                        /* @var $token string */
                                        $token = $this->httpRequest->getQuery("token");
                                
                                
                                Severity: Major
                                Found in MultipleFileUpload/UI/Plupload/Controller.php - About 3 hrs to fix

                                  Function FileReader has 94 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                      function FileReader() {
                                          var self = this, _fr;
                                                  
                                          Basic.extend(this, {
                                              /**
                                  Severity: Major
                                  Found in public/plupload/js/moxie.js - About 3 hrs to fix

                                    Function initControls has 94 lines of code (exceeds 25 allowed). Consider refactoring.
                                    Open

                                        function initControls(settings, cb) {
                                            var self = this, inited = 0, queue = [];
                                    
                                            // common settings
                                            var options = {
                                    Severity: Major
                                    Found in public/plupload/js/plupload.dev.js - About 3 hrs to fix

                                      Function SilverlightRuntime has 92 lines of code (exceeds 25 allowed). Consider refactoring.
                                      Open

                                          function SilverlightRuntime(options) {
                                              var I = this, initTimer;
                                      
                                              options = Basic.extend({ xap_url: Env.xap_url }, options);
                                      
                                      
                                      Severity: Major
                                      Found in public/plupload/js/moxie.js - About 3 hrs to fix
                                        Severity
                                        Category
                                        Status
                                        Source
                                        Language