From dcf2ba4afc2eec720d6ae6df4be1b290cc91563c Mon Sep 17 00:00:00 2001
From: LarsVomMars
Date: Fri, 29 Jan 2021 11:19:49 +0100
Subject: Overwrite files

---
 profile/index.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'profile/index.js')

diff --git a/profile/index.js b/profile/index.js
index be0c232..41de0d5 100644
--- a/profile/index.js
+++ b/profile/index.js
@@ -75,7 +75,7 @@ async function answerImage(req, res, qs) {
         for (const fid in req.files) {
             if (!req.files.hasOwnProperty(fid)) continue;
             const image = req.files[fid];
-            const name = `${req.session.uid}_${new Date().getTime()}.jpg`;
+            const name = `child_${req.session.uid}.jpg`;
             try {
                 await image.mv(`${__dirname}/public/uploads/${name}`);
                 await db.query(qs, [name, fid, req.session.uid]);
-- 
cgit v1.2.3