Skip to content

Commit

Permalink
Merge pull request #297 from Ohtuilmo/fix/all_timelogs_visible
Browse files Browse the repository at this point in the history
fix: all timelogs being visible to all students
  • Loading branch information
miahro authored Apr 30, 2024
2 parents 1daeb1a + 4e1c7ab commit 0c403e3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion backend/controllers/timeLogs.js
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ const fetchAllFromDb = async () => {

timeLogsRouter.get('/', checkLogin, async (req, res) => {
try {
if (req.user.admin || req.user.instructor) {
if (req.user.admin) {
const timeLogs = await fetchAllFromDb()
return res.status(200).json(timeLogs)
}
Expand Down

0 comments on commit 0c403e3

Please sign in to comment.