Changeset 3657


Ignore:
Timestamp:
Jul 21, 2009, 10:09:11 PM (15 years ago)
Author:
plg
Message:

merge r3656 from branch 2.0 to trunk

feature 953: avoid fatal error when delete a photo (added with pwg.images.add
API) and the file doesn't not exist on the filesystem.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/admin/include/functions.php

    r3621 r3657  
    172172      foreach (array($file_path, $thumbnail_path, $high_path) as $path)
    173173      {
    174         if (isset($path) and !unlink($path))
     174        if (isset($path) and is_file($path) and !unlink($path))
    175175        {
    176176          die('"'.$path.'" cannot be removed');
Note: See TracChangeset for help on using the changeset viewer.