Skip to content

pr: [Nightly Fix] - Null Safety - Guard Empty Upload Requests#40

Open
jewel-claw wants to merge 1 commit into
masterfrom
nightly-fix/upload-file-request-guard
Open

pr: [Nightly Fix] - Null Safety - Guard Empty Upload Requests#40
jewel-claw wants to merge 1 commit into
masterfrom
nightly-fix/upload-file-request-guard

Conversation

@jewel-claw

Copy link
Copy Markdown

What

The admin image upload handler reads $_FILES["file"] before checking whether a file was actually uploaded.

Why

Malformed or empty upload requests generate PHP warnings instead of returning a clean validation error to the UI.

Fix

Reject requests that do not contain a valid uploaded file before dereferencing $_FILES["file"].

Confidence

Confirmed in code review and validated with php -l on the modified file.

@greptile-apps

greptile-apps Bot commented Mar 12, 2026

Copy link
Copy Markdown

PR author is not in the allowed authors list.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant