Chocobozzz/PeerTube

View on GitHub

Showing 3,313 of 3,313 total issues

Avoid too many return statements within this function.
Open

      if (!o.live) return undefined
Severity: Major
Found in server/core/lib/user-import-export/importers/videos-importer.ts - About 30 mins to fix

    Avoid too many return statements within this function.
    Open

        return pick(o, [
          'name',
          'duration',
          'channel',
          'privacy',
    Severity: Major
    Found in server/core/lib/user-import-export/importers/videos-importer.ts - About 30 mins to fix

      Avoid too many return statements within this function.
      Open

          return null
      Severity: Major
      Found in server/core/lib/job-queue/handlers/activitypub-cleaner.ts - About 30 mins to fix

        Avoid too many return statements within this function.
        Open

          return Promise.resolve(undefined)
        Severity: Major
        Found in server/core/lib/activitypub/process/process-create.ts - About 30 mins to fix

          Avoid too many return statements within this function.
          Open

            if (diffSeconds >= 15 * aDay) return '1 day'
          Severity: Major
          Found in server/core/lib/timeserie.ts - About 30 mins to fix

            Avoid too many return statements within this function.
            Open

              return '1 minute'
            Severity: Major
            Found in server/core/lib/timeserie.ts - About 30 mins to fix

              Avoid too many return statements within this function.
              Open

                return AccountAutomaticTagPolicyModel.hasPolicyOnTags({
                  accountId: video.VideoChannel.accountId,
                  policy: AutomaticTagPolicy.REVIEW_COMMENT,
                  tags: ownerAccountTags,
                  transaction
              Severity: Major
              Found in server/core/lib/video-comment.ts - About 30 mins to fix

                Avoid too many return statements within this function.
                Open

                    if (o.isLive !== true && !o.archiveFiles?.videoFile) return undefined
                Severity: Major
                Found in server/core/lib/user-import-export/importers/videos-importer.ts - About 30 mins to fix

                  Avoid too many return statements within this function.
                  Open

                    if (diffSeconds >= 15 * anHour) return '1 hour'
                  Severity: Major
                  Found in server/core/lib/timeserie.ts - About 30 mins to fix

                    Avoid too many return statements within this function.
                    Open

                          if (o.passwords.some(p => !isPasswordValid(p))) return undefined
                    Severity: Major
                    Found in server/core/lib/user-import-export/importers/videos-importer.ts - About 30 mins to fix

                      Avoid too many return statements within this function.
                      Open

                        return undefined
                      Severity: Major
                      Found in server/core/lib/activitypub/process/process-undo.ts - About 30 mins to fix

                        Avoid too many return statements within this function.
                        Open

                          return undefined
                        Severity: Major
                        Found in server/core/lib/activitypub/process/process-update.ts - About 30 mins to fix

                          Avoid too many return statements within this function.
                          Open

                                if (!isArray(o.passwords)) return undefined
                          Severity: Major
                          Found in server/core/lib/user-import-export/importers/videos-importer.ts - About 30 mins to fix

                            Avoid too many return statements within this function.
                            Open

                              if (diffSeconds >= 180 * aMinute) return '10 minutes'
                            Severity: Major
                            Found in server/core/lib/timeserie.ts - About 30 mins to fix

                              Avoid too many return statements within this function.
                              Open

                                    if (o.live.saveReplay && !isVideoReplayPrivacyValid(o.live.replaySettings.privacy)) return undefined
                              Severity: Major
                              Found in server/core/lib/user-import-export/importers/videos-importer.ts - About 30 mins to fix

                                Avoid too many return statements within this function.
                                Open

                                    return pick(o, [ 'type', 'displayName', 'privacy', 'elements', 'channel', 'description', 'archiveFiles' ])
                                Severity: Major
                                Found in server/core/lib/user-import-export/importers/video-playlists-importer.ts - About 30 mins to fix

                                  Avoid too many return statements within this function.
                                  Open

                                        if (!isBooleanValid(o.live.permanentLive)) return undefined
                                  Severity: Major
                                  Found in server/core/lib/user-import-export/importers/videos-importer.ts - About 30 mins to fix

                                    Avoid too many return statements within this function.
                                    Open

                                        return { input: stream, isTmpDestination: false }
                                    Severity: Major
                                    Found in server/core/lib/video-file.ts - About 30 mins to fix

                                      Avoid too many return statements within this function.
                                      Open

                                        if (diffSeconds >= 8 * aDay) return '12 hours'
                                      Severity: Major
                                      Found in server/core/lib/timeserie.ts - About 30 mins to fix

                                        Avoid too many return statements within this function.
                                        Open

                                          if (diffSeconds >= 4 * aDay) return '6 hours'
                                        Severity: Major
                                        Found in server/core/lib/timeserie.ts - About 30 mins to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language