Skip to content

Commit

Permalink
Removed unused function (#806)
Browse files Browse the repository at this point in the history
To fix: Undefined constant 'FM_EXTENSION'
  • Loading branch information
mhrstmnn committed Jul 7, 2022
1 parent 17de8af commit b24887d
Showing 1 changed file with 0 additions and 21 deletions.
21 changes: 0 additions & 21 deletions tinyfilemanager.php
Original file line number Diff line number Diff line change
Expand Up @@ -2185,27 +2185,6 @@ class="edit-file"><i class="fa fa-pencil-square-o"></i> <?php echo lng('Advanced

// Functions

/**
* Check if the filename is allowed.
* @param string $filename
* @return bool
*/
function fm_is_file_allowed($filename)
{
// By default, no file is allowed
$allowed = false;

if (FM_EXTENSION) {
$ext = strtolower(pathinfo($filename, PATHINFO_EXTENSION));

if (in_array($ext, explode(',', strtolower(FM_EXTENSION)))) {
$allowed = true;
}
}

return $allowed;
}

/**
* Delete file or folder (recursively)
* @param string $path
Expand Down

0 comments on commit b24887d

Please sign in to comment.