Skip to content

Commit 73cfa3f

Browse files
rename controll for better understanding
1 parent 4592e15 commit 73cfa3f

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

controllers/users.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -495,7 +495,7 @@ const filterUsers = async (req, res) => {
495495
}
496496
};
497497

498-
const returnAllUsers = async (req, res) => {
498+
const usersForInDiscord = async (req, res) => {
499499
const data = await userQuery.getDiscordUsers();
500500
return res.json(data);
501501
};
@@ -519,5 +519,5 @@ module.exports = {
519519
addDefaultArchivedRole,
520520
getUserSkills,
521521
filterUsers,
522-
returnAllUsers,
522+
usersForInDiscord,
523523
};

routes/users.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ router.get("/:userId/intro", authenticate, authorizeRoles([SUPERUSER]), users.ge
2121
router.put("/self/intro", authenticate, userValidator.validateJoinData, users.addUserIntro);
2222
router.get("/:id/skills", users.getUserSkills);
2323
router.get("/:id/badges", getUserBadges);
24-
router.patch("/", authenticate, users.returnAllUsers);
24+
router.patch("/", authenticate, users.usersForInDiscord);
2525

2626
// upload.single('profile') -> multer inmemory storage of file for type multipart/form-data
2727
router.post("/picture", authenticate, upload.single("profile"), users.postUserPicture);

0 commit comments

Comments
 (0)