We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 154d349 commit 31e286cCopy full SHA for 31e286c
src/Response.php
@@ -517,9 +517,7 @@ protected function sendHeaders() : void
517
if ($this->headersSent || \headers_sent()) {
518
throw new LogicException('Headers are already sent');
519
}
520
- if ($this->getHeader(ResponseHeader::DATE) === null) {
521
- $this->setDate();
522
- }
+ $this->negotiateDate();
523
$this->negotiateContentType();
524
$this->negotiateEtag();
525
$this->negotiateCsp();
@@ -668,6 +666,13 @@ protected function negotiateEtag() : void
668
666
669
667
670
+ protected function negotiateDate() : void
+ {
671
+ if ($this->getHeader(ResponseHeader::DATE) === null) {
672
+ $this->setDate();
673
+ }
674
675
+
676
/**
677
* Set Response body and Content-Type as JSON.
678
*
0 commit comments