Updated to Drupal 8.6.4, which is PHP 7.3 friendly. Also updated HTMLaw library....
[yaffs-website] / web / core / modules / dynamic_page_cache / src / PageCache / RequestPolicy / DefaultRequestPolicy.php
1 <?php
2
3 namespace Drupal\dynamic_page_cache\PageCache\RequestPolicy;
4
5 use Drupal\Core\PageCache\ChainRequestPolicy;
6 use Drupal\Core\PageCache\RequestPolicy\CommandLineOrUnsafeMethod;
7
8 /**
9  * The default Dynamic Page Cache request policy.
10  *
11  * Delivery of cached pages is denied if either the application is running from
12  * the command line or the request was not initiated with a safe method (GET or
13  * HEAD).
14  */
15 class DefaultRequestPolicy extends ChainRequestPolicy {
16
17   /**
18    * Constructs the default Dynamic Page Cache request policy.
19    */
20   public function __construct() {
21     $this->addPolicy(new CommandLineOrUnsafeMethod());
22   }
23
24 }