Final Improvement for CV Editor #2
All checks were successful
Neutral/pipeline/head This commit looks good
All checks were successful
Neutral/pipeline/head This commit looks good
This commit is contained in:
parent
eafa16e46d
commit
ee51c4fe8a
@ -167,13 +167,14 @@ router.post("/", function(req, res, next) {
|
|||||||
} else if(req.headers.uploadforproject != null) {
|
} else if(req.headers.uploadforproject != null) {
|
||||||
|
|
||||||
const projectFolder = "/home/gitlab-ci/cv/dashboard-raphael/public/images/"
|
const projectFolder = "/home/gitlab-ci/cv/dashboard-raphael/public/images/"
|
||||||
|
|
||||||
if(fs.existsSync(projectFolder)) {
|
if(fs.existsSync(projectFolder)) {
|
||||||
|
|
||||||
image.mv(projectFolder + req.headers.uploadforproject + ".png", (error) => {
|
image.mv(projectFolder + req.headers.uploadforproject + ".png", (error) => {
|
||||||
|
|
||||||
if(error) {
|
if(error) {
|
||||||
res.send({"result":"ERROR"})
|
res.send({"result":"ERROR"})
|
||||||
|
console.log(err)
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user