File tree Expand file tree Collapse file tree 4 files changed +11
-8
lines changed Expand file tree Collapse file tree 4 files changed +11
-8
lines changed Original file line number Diff line number Diff line change 1- # PHP HTTP Response
1+ # PHP HTTP Response Headers
22
33** Simple PHP package to easily send the right HTTP header responses to the browser 🐘**
44
Original file line number Diff line number Diff line change 11{
22 "name" : " ph-7/php-http-response-header" ,
3- "description" : " A simple package to send HTTP header responses from your PHP application" ,
3+ "description" : " A simple package to send HTTP response headers from your PHP application" ,
44 "keywords" : [
55 " HTTP status code" ,
66 " status code" ,
Original file line number Diff line number Diff line change 11<?xml version =" 1.0" encoding =" utf-8" ?>
2- <phpunit xmlns : xsi =" http://www.w3.org/2001/XMLSchema-instance" bootstrap =" vendor/autoload.php" colors =" true" xsi : noNamespaceSchemaLocation =" https://schema.phpunit.de/10.2/phpunit.xsd" cacheDirectory =" .phpunit.cache" >
3- <coverage />
4- <testsuites >
2+ <phpunit
3+ xmlns : xsi =" http://www.w3.org/2001/XMLSchema-instance"
4+ xsi : noNamespaceSchemaLocation =" https://schema.phpunit.de/|version|/phpunit.xsd"
5+ bootstrap =" vendor/autoload.php"
6+ colors =" true"
7+ cacheDirectory =" .phpunit.cache" >
8+ <testsuites >
59 <testsuite name =" Unit Tests" >
610 <directory >tests</directory >
711 </testsuite >
Original file line number Diff line number Diff line change @@ -108,8 +108,7 @@ public static function getHeadersList(): array
108108 */
109109 public static function setHeaders (string |array $ headers ): void
110110 {
111- // Header already sent
112- if (static ::isSent ()) {
111+ if (static ::areHeadersSent ()) {
113112 throw new Exception ('Headers were already sent. ' );
114113 }
115114
@@ -172,7 +171,7 @@ public static function getProtocol(): ?string
172171 *
173172 * @return bool TRUE if the headers were sent, FALSE if not.
174173 */
175- private static function isSent (): bool
174+ private static function areHeadersSent (): bool
176175 {
177176 return headers_sent ();
178177 }
You can’t perform that action at this time.
0 commit comments