Skip to content

Commit

Permalink
Removed unnecessary console.logs
Browse files Browse the repository at this point in the history
  • Loading branch information
patelaryan7751 committed Jul 15, 2023
1 parent 70a451c commit 70cb88d
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 8 deletions.
2 changes: 0 additions & 2 deletions __tests__/test.js
Original file line number Diff line number Diff line change
Expand Up @@ -119,12 +119,10 @@ describe("Todo Application", function () {
.set("Accept", "application/json");
let parsedGroupedPlayersResponse = JSON.parse(groupedPlayersResponse.text);
const playersCount = parsedGroupedPlayersResponse.length;
console.log(parsedGroupedPlayersResponse, "jkkk");
const selectedPlayersId = parsedGroupedPlayersResponse
.map((player) => player.id)
.slice(0, playersCount)
.join(",");
console.log(selectedPlayersId, "hiii");
res = await agent.get(`/sports/${sportId}/session/create`);
csrfToken = extractCSRFToken(res);
const response = await agent.post(`/sessions`).send({
Expand Down
6 changes: 0 additions & 6 deletions routes/sessions.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,6 @@ const { Session, UserSession, Sport, User } = require("../models");

router.post("/", async (request, response) => {
const selectedPlayers = request.body.selectedPlayersId.split(",");
console.log(
request.body.selectedPlayersId,
"mi",
request.body.selectedPlayersId === ""
);
console.log(selectedPlayers[0], "ki");
if (request.body.selectedPlayersId === "") {
request.flash("error", "Please select at least one player");
return response.redirect(`/sports/${request.body.sport_id}/session/create`);
Expand Down

0 comments on commit 70cb88d

Please sign in to comment.