You are here

public function Vcl::get_setting in Fastly 7.2

Fetches setting by condition name.

@name string

Return value

bool

1 call to Vcl::get_setting()
Vcl::prepare_setting in ./fastly.vcl.inc
Prepares setting for insertion.

File

./fastly.vcl.inc, line 511

Class

Vcl
Class to control the VCL handling.

Code

public function get_setting($name) {
  $uri = $this->_version_base_url . '/' . $this->_last_cloned_version . '/request_settings/' . $name;
  $response = $this->_api
    ->makeRequest($uri);
  if ($response->code != 404) {
    return TRUE;
  }
  return FALSE;
}