HaschekSolutions / pictshare

:camera: PictShare is an open source image, mp4, pastebin hosting service with a simple resizing and upload API that you can host yourself. :rice_scene:
https://www.pictshare.net
Apache License 2.0
845 stars 126 forks source link

Delete image #23

Closed soniram closed 7 years ago

soniram commented 7 years ago

Hi, and thanks for sharing pictshare !! Upload is working perfectly but delete has some glitches... I'm using a post call and although delete works, it returns 404 with this html message Warning: unlink(/var/www/vhosts/xxx/xxx.com/upload/delete_temp.csv): No such file or directory in /var/www/vhosts/xxx/xxx.com/models/pictsharemodel.php on line 145. I have the same behavior even if I send the delete url by hand. Am I doing something wrong ?

geek-at commented 7 years ago

thanks :)

The 404 is okay since the image can't be found after being deleted. Might add an error image in the future

soniram commented 7 years ago

Thanks for replying ! An end point like backend.php but for delete, that returns a json response might be more elegant and useful.... :-)

geek-at commented 7 years ago

good idea!