if (!$mask) {
file_put_contents($pathname, $message . "\n", FILE_APPEND);
/var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Log/Engine/FileLog.php /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Log/Engine/FileLog.php, line 142 Cake\Log\Engine\FileLog->log() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Log/Log.php, line 392 Cake\Log\Log::write() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Log/Log.php, line 509 Cake\Log\Log::debug() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/src/Controller/AppController.php, line 86 App\Controller\AppController->initialize() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/src/Controller/LocationController.php, line 19 App\Controller\LocationController->initialize() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/Controller.php, line 242 Cake\Controller\Controller->__construct() [internal], line ?? ReflectionClass->newInstance() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/ControllerFactory.php, line 88 Cake\Controller\ControllerFactory->create() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/BaseApplication.php, line 320 Cake\Http\BaseApplication->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 86 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Middleware/CsrfProtectionMiddleware.php, line 166 Cake\Http\Middleware\CsrfProtectionMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Middleware/BodyParserMiddleware.php, line 157 Cake\Http\Middleware\BodyParserMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Routing/Middleware/RoutingMiddleware.php, line 189 Cake\Routing\Middleware\RoutingMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Routing/Middleware/AssetMiddleware.php, line 68 Cake\Routing\Middleware\AssetMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Error/Middleware/ErrorHandlerMiddleware.php, line 149 Cake\Error\Middleware\ErrorHandlerMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 67 Cake\Http\Runner->run() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Server.php, line 99 Cake\Http\Server->run() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/webroot/index.php, line 37 [main]
$success = $this->_File->ftruncate(0) &&
$this->_File->fwrite($contents) &&
$this->_File->fflush();
SplFileObject->fwrite() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Cache/Engine/FileEngine.php, line 142 Cake\Cache\Engine\FileEngine->set() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/I18n/TranslatorRegistry.php, line 211 Cake\I18n\TranslatorRegistry->get() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/I18n/TranslatorRegistry.php, line 255 Cake\I18n\TranslatorRegistry->createInstance() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/I18n/TranslatorRegistry.php, line 240 Cake\I18n\TranslatorRegistry->_getTranslator() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/I18n/TranslatorRegistry.php, line 210 Cake\I18n\TranslatorRegistry->get() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/I18n/I18n.php, line 148 Cake\I18n\I18n::getTranslator() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/I18n/functions.php, line 89 /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/Component/AuthComponent.php /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/Component/AuthComponent.php, line 463 Cake\Controller\Component\AuthComponent->_setDefaults() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/Component/AuthComponent.php, line 276 Cake\Controller\Component\AuthComponent->authCheck() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/Component/AuthComponent.php, line 248 Cake\Controller\Component\AuthComponent->startup() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Event/EventManager.php, line 309 Cake\Event\EventManager->_callListener() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Event/EventManager.php, line 286 Cake\Event\EventManager->dispatch() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Event/EventDispatcherTrait.php, line 92 Cake\Controller\Controller->dispatchEvent() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/Controller.php, line 661 Cake\Controller\Controller->startupProcess() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/ControllerFactory.php, line 130 Cake\Controller\ControllerFactory->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/ControllerFactory.php, line 115 Cake\Controller\ControllerFactory->invoke() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/BaseApplication.php, line 325 Cake\Http\BaseApplication->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 86 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Middleware/CsrfProtectionMiddleware.php, line 166 Cake\Http\Middleware\CsrfProtectionMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Middleware/BodyParserMiddleware.php, line 157 Cake\Http\Middleware\BodyParserMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Routing/Middleware/RoutingMiddleware.php, line 189 Cake\Routing\Middleware\RoutingMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Routing/Middleware/AssetMiddleware.php, line 68 Cake\Routing\Middleware\AssetMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Error/Middleware/ErrorHandlerMiddleware.php, line 149 Cake\Error\Middleware\ErrorHandlerMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 67 Cake\Http\Runner->run() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Server.php, line 99 Cake\Http\Server->run() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/webroot/index.php, line 37 [main]
$success = $this->_File->ftruncate(0) &&
$this->_File->fwrite($contents) &&
$this->_File->fflush();
SplFileObject->fwrite() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Cache/Engine/FileEngine.php, line 142 Cake\Cache\Engine\FileEngine->set() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/I18n/TranslatorRegistry.php, line 211 Cake\I18n\TranslatorRegistry->get() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/I18n/I18n.php, line 148 Cake\I18n\I18n::getTranslator() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/I18n/functions.php, line 89 /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/Component/AuthComponent.php /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/Component/AuthComponent.php, line 463 Cake\Controller\Component\AuthComponent->_setDefaults() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/Component/AuthComponent.php, line 276 Cake\Controller\Component\AuthComponent->authCheck() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/Component/AuthComponent.php, line 248 Cake\Controller\Component\AuthComponent->startup() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Event/EventManager.php, line 309 Cake\Event\EventManager->_callListener() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Event/EventManager.php, line 286 Cake\Event\EventManager->dispatch() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Event/EventDispatcherTrait.php, line 92 Cake\Controller\Controller->dispatchEvent() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/Controller.php, line 661 Cake\Controller\Controller->startupProcess() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/ControllerFactory.php, line 130 Cake\Controller\ControllerFactory->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/ControllerFactory.php, line 115 Cake\Controller\ControllerFactory->invoke() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/BaseApplication.php, line 325 Cake\Http\BaseApplication->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 86 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Middleware/CsrfProtectionMiddleware.php, line 166 Cake\Http\Middleware\CsrfProtectionMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Middleware/BodyParserMiddleware.php, line 157 Cake\Http\Middleware\BodyParserMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Routing/Middleware/RoutingMiddleware.php, line 189 Cake\Routing\Middleware\RoutingMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Routing/Middleware/AssetMiddleware.php, line 68 Cake\Routing\Middleware\AssetMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Error/Middleware/ErrorHandlerMiddleware.php, line 149 Cake\Error\Middleware\ErrorHandlerMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 67 Cake\Http\Runner->run() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Server.php, line 99 Cake\Http\Server->run() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/webroot/index.php, line 37 [main]
if ($data !== '' && !empty($this->_config['serialize'])) {
$data = unserialize($data);
}
/var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Cache/Engine/FileEngine.php /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Cache/Engine/FileEngine.php, line 203 Cake\Cache\Engine\FileEngine->get() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Database/Schema/CachedCollection.php, line 86 Cake\Database\Schema\CachedCollection->describe() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/ORM/Table.php, line 528 Cake\ORM\Table->getSchema() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/ORM/Query.php, line 309 Cake\ORM\Query->addDefaultTypes() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/ORM/Query.php, line 528 Cake\ORM\Query->_addAssociationsToTypeMap() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/ORM/Query.php, line 478 Cake\ORM\Query->contain() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/ORM/Query.php, line 867 Cake\ORM\Query->applyOptions() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/ORM/Table.php, line 2611 Cake\ORM\Table->callFinder() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/ORM/Table.php, line 1281 Cake\ORM\Table->find() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/ORM/Table.php, line 1553 Cake\ORM\Table->get() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/src/Controller/LocationController.php, line 503 App\Controller\LocationController->view() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/Controller.php, line 560 Cake\Controller\Controller->invokeAction() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/ControllerFactory.php, line 140 Cake\Controller\ControllerFactory->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Controller/ControllerFactory.php, line 115 Cake\Controller\ControllerFactory->invoke() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/BaseApplication.php, line 325 Cake\Http\BaseApplication->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 86 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Middleware/CsrfProtectionMiddleware.php, line 166 Cake\Http\Middleware\CsrfProtectionMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Middleware/BodyParserMiddleware.php, line 157 Cake\Http\Middleware\BodyParserMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Routing/Middleware/RoutingMiddleware.php, line 189 Cake\Routing\Middleware\RoutingMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Routing/Middleware/AssetMiddleware.php, line 68 Cake\Routing\Middleware\AssetMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Error/Middleware/ErrorHandlerMiddleware.php, line 149 Cake\Error\Middleware\ErrorHandlerMiddleware->process() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Runner.php, line 67 Cake\Http\Runner->run() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Server.php, line 99 Cake\Http\Server->run() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/webroot/index.php, line 37 [main]
$message = "Unable to emit headers. Headers sent in file=$file line=$line";
trigger_error($message, E_USER_WARNING);
}
/var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php, line 71 Cake\Http\ResponseEmitter->emit() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Server.php, line 137 Cake\Http\Server->emit() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/webroot/index.php, line 37 [main]
$reasonPhrase = $response->getReasonPhrase();
header(sprintf(
'HTTP/%s %d%s',
/var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php, line 164 Cake\Http\ResponseEmitter->emitStatusLine() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php, line 74 Cake\Http\ResponseEmitter->emit() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Server.php, line 137 Cake\Http\Server->emit() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/webroot/index.php, line 37 [main]
foreach ($values as $value) {
header(sprintf(
'%s: %s',
/var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php, line 197 Cake\Http\ResponseEmitter->emitHeaders() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php, line 75 Cake\Http\ResponseEmitter->emit() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/vendor/cakephp/cakephp/src/Http/Server.php, line 137 Cake\Http\Server->emit() /var/www/mapa.conflictosmineros.net/ocmal_db-v2/webroot/index.php, line 37 [main]
|
|
if (!$options['forceRefresh']) { |
|
$cached = $this->cacher->get($cacheKey); |
|
if ($cached !== null) { |
|
return $cached; |
|
} |
|
} |
|
|
|
$table = $this->collection->describe($name, $options); |
{ |
|
if ($this->_schema === null) { |
|
$this->_schema = $this->getConnection() |
|
->getSchemaCollection() |
|
->describe($this->getTable()); |
|
|
|
$method = new ReflectionMethod($this, '_initializeSchema'); |
|
if ($method->getDeclaringClass()->getName() != Table::class) { |
|
deprecationWarning( |
*/ |
|
public function addDefaultTypes(Table $table) |
|
{ |
|
$alias = $table->getAlias(); |
|
$map = $table->getSchema()->typeMap(); |
|
$fields = []; |
|
foreach ($map as $f => $type) { |
|
$fields[$f] = $fields[$alias . '.' . $f] = $fields[$alias . '__' . $f] = $type; |
|
} |
$association = $table->getAssociation($name); |
|
$target = $association->getTarget(); |
|
$primary = (array)$target->getPrimaryKey(); |
|
if (empty($primary) || $typeMap->type($target->aliasField($primary[0])) === null) { |
|
$this->addDefaultTypes($target); |
|
} |
|
if (!empty($nested)) { |
|
$this->_addAssociationsToTypeMap($target, $typeMap, $nested); |
|
} |
|
|
if ($associations) { |
|
$loader->contain($associations, $queryBuilder); |
|
} |
|
$this->_addAssociationsToTypeMap( |
|
$this->getRepository(), |
|
$this->getTypeMap(), |
|
$loader->getContain() |
|
); |
|
|
ksort($options); |
|
foreach ($options as $option => $values) { |
|
if (isset($valid[$option], $values)) { |
|
$this->{$valid[$option]}($values); |
|
} else { |
|
$this->_options[$option] = $values; |
|
} |
|
} |
* @uses findThreaded() |
|
*/ |
|
public function callFinder(string $type, Query $query, array $options = []): Query |
|
{ |
|
$query->applyOptions($options); |
|
$options = $query->getOptions(); |
|
$finder = 'find' . $type; |
|
if (method_exists($this, $finder)) { |
|
return $this->{$finder}($query, $options); |
* @return \Cake\ORM\Query The query builder |
|
*/ |
|
public function find(string $type = 'all', array $options = []): Query |
|
{ |
|
return $this->callFinder($type, $this->selectQuery()->select(), $options); |
|
} |
|
|
|
/** |
|
* Returns the query as passed. |
$cacheKey = $options['key'] ?? false; |
|
$finder = $options['finder'] ?? 'all'; |
|
unset($options['key'], $options['cache'], $options['finder']); |
|
|
|
$query = $this->find($finder, $options)->where($conditions); |
|
|
|
if ($cacheConfig) { |
|
if (!$cacheKey) { |
|
$cacheKey = sprintf( |
* @throws \Cake\Datasource\Exception\RecordNotFoundException When record not found. |
|
*/ |
|
public function view($id = null) |
|
{ |
|
$location = $this->Location->get($id, [ |
|
'contain' => [ 'LocationPais','Incident', 'Media'] |
|
]); |
|
$this->set('title',h($location->location_name)); |
|
$this->set('location', $location); |
* @throws \UnexpectedValueException If return value of action is not `null` or `ResponseInterface` instance. |
|
*/ |
|
public function invokeAction(Closure $action, array $args): void |
|
{ |
|
$result = $action(...$args); |
|
if ($result !== null && !$result instanceof ResponseInterface) { |
|
throw new UnexpectedValueException(sprintf( |
|
'Controller actions can only return ResponseInterface instance or null. ' |
|
. 'Got %s instead.', |
$args = $this->getActionArgs( |
|
$action, |
|
array_values((array)$controller->getRequest()->getParam('pass')) |
|
); |
|
$controller->invokeAction($action, $args); |
|
|
|
$result = $controller->shutdownProcess(); |
|
if ($result instanceof ResponseInterface) { |
|
return $result; |
|
|
return $runner->run($middlewareQueue, $controller->getRequest(), $this); |
|
} |
|
|
|
return $this->handle($controller->getRequest()); |
|
} |
|
|
|
/** |
|
* Invoke the action. |
|
|
// This is needed for auto-wiring. Should be removed in 5.x |
|
$container->add(ComponentRegistry::class, $controller->components()); |
|
|
|
return $this->controllerFactory->invoke($controller); |
|
} |
|
} |
|
|
return $middleware->process($request, $this); |
|
} |
|
|
|
if ($this->fallbackHandler) { |
|
return $this->fallbackHandler->handle($request); |
|
} |
|
|
|
return new Response([ |
|
'body' => 'Middleware queue was exhausted without returning a response ' |
if ($method === 'GET' && $cookieData === null) { |
|
$token = $this->createToken(); |
|
$request = $request->withAttribute('csrfToken', $this->saltToken($token)); |
|
/** @var mixed $response */ |
|
$response = $handler->handle($request); |
|
|
|
return $this->_addTokenCookie($token, $request, $response); |
|
} |
|
|
if ($this->queue->valid()) { |
|
$middleware = $this->queue->current(); |
|
$this->queue->next(); |
|
|
|
return $middleware->process($request, $this); |
|
} |
|
|
|
if ($this->fallbackHandler) { |
|
return $this->fallbackHandler->handle($request); |
*/ |
|
public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface |
|
{ |
|
if (!in_array($request->getMethod(), $this->methods, true)) { |
|
return $handler->handle($request); |
|
} |
|
[$type] = explode(';', $request->getHeaderLine('Content-Type')); |
|
$type = strtolower($type); |
|
if (!isset($this->parsers[$type])) { |
if ($this->queue->valid()) { |
|
$middleware = $this->queue->current(); |
|
$this->queue->next(); |
|
|
|
return $middleware->process($request, $this); |
|
} |
|
|
|
if ($this->fallbackHandler) { |
|
return $this->fallbackHandler->handle($request); |
); |
|
} |
|
$matching = Router::getRouteCollection()->getMiddleware($middleware); |
|
if (!$matching) { |
|
return $handler->handle($request); |
|
} |
|
|
|
$container = $this->app instanceof ContainerApplicationInterface |
|
? $this->app->getContainer() |
if ($this->queue->valid()) { |
|
$middleware = $this->queue->current(); |
|
$this->queue->next(); |
|
|
|
return $middleware->process($request, $this); |
|
} |
|
|
|
if ($this->fallbackHandler) { |
|
return $this->fallbackHandler->handle($request); |
public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface |
|
{ |
|
$url = $request->getUri()->getPath(); |
|
if (strpos($url, '..') !== false || strpos($url, '.') === false) { |
|
return $handler->handle($request); |
|
} |
|
|
|
if (strpos($url, '/.') !== false) { |
|
return $handler->handle($request); |
if ($this->queue->valid()) { |
|
$middleware = $this->queue->current(); |
|
$this->queue->next(); |
|
|
|
return $middleware->process($request, $this); |
|
} |
|
|
|
if ($this->fallbackHandler) { |
|
return $this->fallbackHandler->handle($request); |
*/ |
|
public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface |
|
{ |
|
try { |
|
return $handler->handle($request); |
|
} catch (RedirectException $exception) { |
|
return $this->handleRedirect($exception); |
|
} catch (Throwable $exception) { |
|
return $this->handleException($exception, $request); |
if ($this->queue->valid()) { |
|
$middleware = $this->queue->current(); |
|
$this->queue->next(); |
|
|
|
return $middleware->process($request, $this); |
|
} |
|
|
|
if ($this->fallbackHandler) { |
|
return $this->fallbackHandler->handle($request); |
) { |
|
Router::setRequest($request); |
|
} |
|
|
|
return $this->handle($request); |
|
} |
|
|
|
/** |
|
* Handle incoming server request and return a response. |
} |
|
|
|
$this->dispatchEvent('Server.buildMiddleware', ['middleware' => $middleware]); |
|
|
|
$response = $this->runner->run($middleware, $request, $this->app); |
|
|
|
if ($request instanceof ServerRequest) { |
|
$request->getSession()->close(); |
|
} |
$server = new Server(new Application(dirname(__DIR__) . '/config')); |
|
|
|
// Run the request/response through the application |
|
// and emit the response. |
|
$server->emit($server->run()); |
|
|
If you want to customize this error message, create templates/Error/error500.ctp