From 15ac753c1592e85954098f3c0155807af14133de Mon Sep 17 00:00:00 2001 From: "stephen@cubedesigners.com" Date: Wed, 24 May 2017 16:30:51 +0000 Subject: [PATCH] Debug problem with zoom zone files filling /tmp partition. WIP #1395 @1.5 --- inc/ws/Util/html5/master/class.ws.html5.links.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/inc/ws/Util/html5/master/class.ws.html5.links.php b/inc/ws/Util/html5/master/class.ws.html5.links.php index b54ef1bf6..95c8df480 100644 --- a/inc/ws/Util/html5/master/class.ws.html5.links.php +++ b/inc/ws/Util/html5/master/class.ws.html5.links.php @@ -1142,6 +1142,14 @@ class zoomLink extends normalLink { } $this->compiler->simpleCopyLinkFile($both, 'data/links/zoom_' . $this->id . '.jpg'); + + // Perform tidy up and delete temporary files if they exist + $files_to_delete = ['left', 'leftfile', 'right', 'rightfile', 'both']; + foreach($files_to_delete as $file) { + if (isset($$file) && file_exists($$file)) { + unlink($$file); + } + } } -- 2.39.5