Skip to content

Commit e24959d

Browse files
committed
fix: reset all sessions + warning
1 parent f8a716a commit e24959d

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

client/src/assets/ReactivateIcon.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import React from 'react';
55
export const ReactivateIcon = () => {
66
return (
77
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
8-
<path fillRule="evenodd" clipRule="evenodd" d="M18.3334 17.0148C16.2945 14.5259 14.484 13.1137 12.9017 12.7782C11.3195 12.4426 9.81314 12.3919 8.38258 12.6261V17.0832L1.66675 9.81025L8.38258 2.9165V7.15275C11.0279 7.17359 13.2767 8.12262 15.1292 9.99984C16.9815 11.8771 18.0495 14.2154 18.3334 17.0148Z" fill="#767778" stroke="#767778" strokeWidth="2" strokeLineJoin="round"/>
8+
<path fillRule="evenodd" clipRule="evenodd" d="M18.3334 17.0148C16.2945 14.5259 14.484 13.1137 12.9017 12.7782C11.3195 12.4426 9.81314 12.3919 8.38258 12.6261V17.0832L1.66675 9.81025L8.38258 2.9165V7.15275C11.0279 7.17359 13.2767 8.12262 15.1292 9.99984C16.9815 11.8771 18.0495 14.2154 18.3334 17.0148Z" fill="#767778" stroke="#767778" strokeWidth="2" strokeLinejoin="round"/>
99
</svg>
1010

1111
);

server/routes/assignments.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -145,8 +145,8 @@ assignmentsRouter.put("/:id", async (req, res) => {
145145
assignmentsRouter.delete("/:id", async (req, res) => {
146146
try {
147147
const { id } = req.params;
148-
const data = await db.query("DELETE FROM assignments WHERE id = $1", [id]);
149-
if (data.length === 0) {
148+
const data = await db.query("DELETE FROM assignments WHERE id = $1 RETURNING *", [id]);
149+
if (!data || data.length === 0) {
150150
return res
151151
.status(404)
152152
.json({ result: "error", message: "Assignment not found" });
@@ -160,10 +160,10 @@ assignmentsRouter.delete("/:id", async (req, res) => {
160160
assignmentsRouter.delete("/event/:id", async (req, res) => {
161161
try {
162162
const { id } = req.params;
163-
const data = await db.query("DELETE FROM assignments WHERE event_id = $1", [
163+
const data = await db.query("DELETE FROM assignments WHERE event_id = $1 RETURNING *", [
164164
id,
165165
]);
166-
if (data.length === 0) {
166+
if (!data || data.length === 0) {
167167
return res
168168
.status(404)
169169
.json({ result: "error", message: "Assignment not found" });

0 commit comments

Comments
 (0)