Skip to content

Commit e468432

Browse files
authored
Add files via upload
1 parent 1f54415 commit e468432

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

file-uploader.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,9 @@ function upload ($file = null, $uploadFolder = null) : string {
4545
// TODO : Make $EXTENSIONS_ALLOWED variable a constant?
4646
$EXTENSIONS_ALLOWED = ["PNG", "JPG", "JPEG", "PDF"];
4747

48-
// Set a boolean-flag
48+
// Set $is_allowed boolean-flag
4949
// This flag will tell whether an extension is allowed
50-
// Loop through the list of allowed extensions, compare element with file extension
50+
// Loop through the list of allowed extensions, compare each element with file extension
5151
// Set $is_allowed = true if file extension is in the list of allowed file extensions, then break out of the loop
5252
$is_allowed = false;
5353
foreach ($EXTENSIONS_ALLOWED as $value) {

0 commit comments

Comments
 (0)