From 13ef38d7b72085dbf436fa62f1b5ae76a88df3bd Mon Sep 17 00:00:00 2001 From: Savetheinternet Date: Sat, 19 Feb 2011 19:28:07 +1100 Subject: Delete images properly on error --- inc/functions.php | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'inc') diff --git a/inc/functions.php b/inc/functions.php index d0929eef..535defb5 100644 --- a/inc/functions.php +++ b/inc/functions.php @@ -1122,7 +1122,14 @@ return $res; } + function undoImage($post) { + unlink($post['file']); + unlink($post['thumb']); + } + function createimage($type, $source_pic) { + global $config; + $image = false; switch($type) { case 'jpg': -- cgit v1.3