Merge pull request #369 from catalyst/368-clean-ob

[#368] Ensure output buffer is empty before serving files
This commit is contained in:
Kevin Pham
2025-02-27 11:27:51 +11:00
committed by GitHub

View File

@@ -69,6 +69,11 @@ function auth_outage_bootstrap_callback() {
http_response_code(404);
die('File not found.');
}
// Ensure there is nothing in the output buffer.
// otherwise the file will not be read correctly.
ob_clean();
readfile($file);
exit(0);
}