owncloud/core

View on GitHub

Showing 3,235 of 4,504 total issues

Function launchNext has 38 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    this.launchNext = function() {
        var currentCounter = this.counter++;
        if (currentCounter in this.functionList) {
            var funcData = this.functionList[currentCounter];
            if ($.isFunction(funcData.funcName)) {
Severity: Minor
Found in apps/files_external/js/rollingqueue.js - About 1 hr to fix

    Function ensureFolderExists has 38 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        ensureFolderExists: function(fullPath) {
            if (!fullPath || fullPath === '/') {
                return $.Deferred().resolve().promise();
            }
    
    
    Severity: Minor
    Found in apps/files/js/file-upload.js - About 1 hr to fix

      Function _onSelectTag has 38 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

              _onSelectTag: function(e) {
                  var self = this;
                  var tag;
                  if (e.object && e.object.isNew) {
                      // newly created tag, check if existing
      Severity: Minor
      Found in core/js/systemtags/systemtagsinputfield.js - About 1 hr to fix

        Function getModelForFile has 38 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

                getModelForFile: function(fileName) {
                    var self = this;
                    var $tr;
                    // jQuery object ?
                    if (fileName.is) {
        Severity: Minor
        Found in apps/files/js/filelist.js - About 1 hr to fix

          Function initialize has 38 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

                  initialize: function(options) {
                      var view = this;
          
                      this.model.on('fetchError', function() {
                          OC.Notification.showTemporary(t('core', 'Share details could not be loaded for this item.'));
          Severity: Minor
          Found in core/js/sharedialogview.js - About 1 hr to fix

            Function share has 38 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                share:function(itemType, itemSource, shareType, shareWith, permissions, itemSourceName, expirationDate, callback, errorCallback) {
                    // Add a fallback for old share() calls without expirationDate.
                    // We should remove this in a later version,
                    // after the Apps have been updated.
                    if (typeof callback === 'undefined' &&
            Severity: Minor
            Found in core/js/share.js - About 1 hr to fix

              Function _afterRender has 38 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                      _afterRender: function () {
                          var _this = this;
              
                          this.$el.find('.emailPrivateLinkForm--emailField').select2({
                              containerCssClass: 'emailPrivateLinkForm--dropDown',
              Severity: Minor
              Found in core/js/sharedialogmailview.js - About 1 hr to fix

                Function search has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                            this.search = function(query, inApps, page, size) {
                                if (query) {
                                    OC.addStyle('core/search','results');
                                    if (typeof page !== 'number') {
                                        page = 1;
                Severity: Minor
                Found in core/search/js/search.js - About 1 hr to fix

                  Method run has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                      protected function run($argument) {
                          $target = $argument['url'];
                          $source = $this->urlGenerator->getAbsoluteURL('/');
                          $source = \rtrim($source, '/');
                          $token = $argument['token'];
                  Severity: Minor
                  Found in apps/federation/lib/BackgroundJob/RequestSharedSecret.php - About 1 hr to fix

                    Method getSharesBy has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                        public function getSharesBy($userId, $shareType, $node, $reshares, $limit, $offset) {
                            $qb = $this->dbConnection->getQueryBuilder();
                            $qb->select('*')
                                ->from($this->shareTable);
                    
                    
                    Severity: Minor
                    Found in apps/federatedfilesharing/lib/FederatedShareProvider.php - About 1 hr to fix

                      Method sql has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                          public function sql(IDBConnection $connection) {
                              $qb = $connection->getQueryBuilder();
                              $qb->select('*')
                                  ->from('properties', 'props')
                                  ->setMaxResults(1);
                      Severity: Minor
                      Found in apps/dav/appinfo/Migrations/Version20170202213905.php - About 1 hr to fix

                        Method getAddressBooksForUser has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                            public function getAddressBooksForUser($principalUri) {
                                $addressBooks = $this->getUsersOwnAddressBooks($principalUri);
                        
                                // query for shared calendars
                                $principals = $this->principalBackend->getGroupMembership($principalUri, true);
                        Severity: Minor
                        Found in apps/dav/lib/CardDAV/CardDavBackend.php - About 1 hr to fix

                          Method verifyChecksumsForFile has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                              private function verifyChecksumsForFile($file, InputInterface $input, OutputInterface $output) {
                                  $path = $file->getInternalPath();
                                  $currentChecksums = $file->getChecksum();
                                  $storage = $file->getStorage();
                                  $storageId = $storage->getId();
                          Severity: Minor
                          Found in apps/files/lib/Command/VerifyChecksums.php - About 1 hr to fix

                            Method searchCommon has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                                private function searchCommon($method, $args) {
                                    $files = [];
                                    $rootLength = \strlen($this->path);
                                    $mount = $this->root->getMount($this->path);
                                    $storage = $mount->getStorage();
                            Severity: Minor
                            Found in lib/private/Files/Node/Folder.php - About 1 hr to fix

                              Method searchCommon has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                  private function searchCommon($method, $args) {
                                      $files = [];
                                      $rootLength = \strlen($this->fakeRoot);
                              
                                      $mount = $this->getMount('');
                              Severity: Minor
                              Found in lib/private/Files/View.php - About 1 hr to fix

                                Method writeBack has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                    public function writeBack($tmpFile) {
                                        if (!isset(self::$tmpFiles[$tmpFile])) {
                                            return;
                                        }
                                
                                
                                Severity: Minor
                                Found in lib/private/Files/ObjectStore/ObjectStoreStorage.php - About 1 hr to fix

                                  Method generatePreview has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                      private function generatePreview() {
                                          $file = $this->getFile();
                                          $preview = null;
                                  
                                          $previewProviders = \OC::$server->getPreviewManager()
                                  Severity: Minor
                                  Found in lib/private/Preview.php - About 1 hr to fix

                                    Method xmlToArray has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                                    Open

                                        protected function xmlToArray($xml) {
                                            if (!$xml->children()) {
                                                return (string)$xml;
                                            }
                                    
                                    
                                    Severity: Minor
                                    Found in lib/private/App/InfoParser.php - About 1 hr to fix

                                      Method getAppInfoByPath has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                                      Open

                                          public function getAppInfoByPath($path, $etag = null) {
                                              $file = \realpath($path);
                                      
                                              // check the cache
                                              $data = $this->appInfo->get($file);
                                      Severity: Minor
                                      Found in lib/private/App/AppManager.php - About 1 hr to fix

                                        Method execute has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                                        Open

                                            protected function execute(InputInterface $input, OutputInterface $output): int {
                                                $groupName = $input->getArgument('group');
                                                $group = $this->groupManager->get($groupName);
                                                $errorFound = false;
                                                if (!$group) {
                                        Severity: Minor
                                        Found in core/Command/Group/AddMember.php - About 1 hr to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language