NodeBB/NodeBB

View on GitHub

Showing 536 of 552 total issues

Avoid too many return statements within this function.
Open

        return next();
Severity: Major
Found in src/middleware/admin.js - About 30 mins to fix

    Avoid too many return statements within this function.
    Open

            return str;
    Severity: Major
    Found in public/src/utils.common.js - About 30 mins to fix

      Avoid too many return statements within this function.
      Open

                      return e.preventDefault();
      Severity: Major
      Found in public/src/ajaxify.js - About 30 mins to fix

        Avoid too many return statements within this function.
        Open

            return true;
        Severity: Major
        Found in src/routes/feeds.js - About 30 mins to fix

          Avoid too many return statements within this function.
          Open

                  return next();
          Severity: Major
          Found in src/controllers/category.js - About 30 mins to fix

            Avoid too many return statements within this function.
            Open

                            return next(new Error('[[error:invalid-login-credentials]]'));
            Severity: Major
            Found in src/controllers/authentication.js - About 30 mins to fix

              Avoid too many return statements within this function.
              Open

                      return helpers.redirect(res, 'admin/manage/tags');
              Severity: Major
              Found in src/controllers/admin.js - About 30 mins to fix

                Avoid too many return statements within this function.
                Open

                        return 'hash';
                Severity: Major
                Found in src/database/mongo/main.js - About 30 mins to fix

                  Avoid too many return statements within this function.
                  Open

                          return helpers.redirect(res, 'admin/manage/admins-mods');
                  Severity: Major
                  Found in src/controllers/admin.js - About 30 mins to fix

                    Avoid too many return statements within this function.
                    Open

                            return helpers.redirect(res, validator.unescape(categoryFields.link));
                    Severity: Major
                    Found in src/controllers/category.js - About 30 mins to fix

                      Avoid too many return statements within this function.
                      Open

                              return { flag: false, message: '[[error:post-deleted]]' };
                      Severity: Major
                      Found in src/privileges/posts.js - About 30 mins to fix

                        Avoid too many return statements within this function.
                        Open

                                return helpers.redirect(res, `/category/${categoryData.slug}/${categoryData.topic_count}?${qs.stringify(req.query)}`);
                        Severity: Major
                        Found in src/controllers/category.js - About 30 mins to fix

                          Avoid too many return statements within this function.
                          Open

                              return { flag: result.edit && (result.owner || result.isMod), message: '[[error:no-privileges]]' };
                          Severity: Major
                          Found in src/privileges/posts.js - About 30 mins to fix

                            Avoid too many return statements within this function.
                            Open

                                    return helpers.redirect(res, `/topic/${tid}/${req.params.slug}${postIndex > topicData.postcount ? `/${topicData.postcount}` : ''}${generateQueryString(req.query)}`);
                            Severity: Major
                            Found in src/controllers/topics.js - About 30 mins to fix

                              Avoid too many return statements within this function.
                              Open

                                  return helpers.notAllowed(req, res);
                              Severity: Major
                              Found in src/controllers/admin.js - About 30 mins to fix

                                Avoid too many return statements within this function.
                                Open

                                        return next();
                                Severity: Major
                                Found in src/controllers/category.js - About 30 mins to fix

                                  Avoid too many return statements within this function.
                                  Open

                                          return next();
                                  Severity: Major
                                  Found in src/controllers/accounts/chats.js - About 30 mins to fix

                                    Avoid too many return statements within this function.
                                    Open

                                            return res.rows[0].e;
                                    Severity: Major
                                    Found in src/database/postgres/main.js - About 30 mins to fix

                                      Avoid too many return statements within this function.
                                      Open

                                                  return next(new Error('[[error:local-login-disabled]]'));
                                      Severity: Major
                                      Found in src/controllers/authentication.js - About 30 mins to fix

                                        Avoid too many return statements within this function.
                                        Open

                                                return helpers.redirect(res, 'admin/settings/general');
                                        Severity: Major
                                        Found in src/controllers/admin.js - About 30 mins to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language