Skip to content
This repository has been archived by the owner on Mar 3, 2024. It is now read-only.

Commit

Permalink
Last minute fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Its-OP committed Mar 3, 2024
1 parent 7cdfbf5 commit b9900b3
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions Backend/Web/Controllers/ActivitiesController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@

namespace backend.Controllers;

[Authorize(Roles = Roles.Professor)]
[Route("api/activities")]
public class ActivitiesController : ControllerBase
{
Expand Down Expand Up @@ -73,7 +72,7 @@ public async Task<IActionResult> CreateActivities([FromRoute] int subjectId,
var activity = new Activity
{
ActivityType = activityType,
ConductedAt = DateTime.Now.AddDays(-(new Random().Next(1, 100))).RoundToMinutes(),
ConductedAt = DateTime.UtcNow.AddDays(-(new Random().Next(1, 100))).RoundToMinutes(),
Score = maxScore > apiActivity.Score ? apiActivity.Score : maxScore,
MaxScore = maxScore,
Student = students[apiActivity.StudentId],
Expand Down

0 comments on commit b9900b3

Please sign in to comment.