Changeset 709 for branches/1.1dev/lib


Ignore:
Timestamp:
Nov 16, 2019 9:14:04 PM (4 years ago)
Author:
anonymous
Message:

Fix PHP notice errors

Location:
branches/1.1dev/lib
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/1.1dev/lib/App.inc.php

    r689 r709  
    297297        // Use non specific boomerang if available.
    298298        $url = end($_SESSION['_boomerang']['url']);
     299    } else {
     300        // If URL is not specified, use the $CFG->redirect_home config value.
     301        $url = $CFG->redirect_home;
    299302    }
    300303
  • branches/1.1dev/lib/Upload.inc.php

    r648 r709  
    576576    {
    577577        preg_match('/.*?\.(\w+)$/i', $file_name, $ext);
    578         return $ext[1];
     578        if (isset($ext[1])) {
     579            return $ext[1];
     580        } else {
     581            logMsg(sprintf('No filename extension found: %s.', $file_name), LOG_NOTICE, __FILE__, __LINE__);
     582            return '';
     583        }
    579584    }
    580585}
    581 
    582 ?>
Note: See TracChangeset for help on using the changeset viewer.