From 3b9c0737113879e662b865d9b2e44cd19bf463e6 Mon Sep 17 00:00:00 2001 From: Jeremy Livingston Date: Tue, 23 Dec 2014 13:17:13 -0500 Subject: [PATCH] Add deprecation warning to LegacyPdoSessionHandler LegacyPdoSessionHandler has been deprecated in favor of PdoSessionHandler. Trigger an E_USER_DEPRECATED error when the deprecated class is used. --- .../Session/Storage/Handler/LegacyPdoSessionHandler.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/Symfony/Component/HttpFoundation/Session/Storage/Handler/LegacyPdoSessionHandler.php b/src/Symfony/Component/HttpFoundation/Session/Storage/Handler/LegacyPdoSessionHandler.php index fff83315aacbe..df31832701d58 100644 --- a/src/Symfony/Component/HttpFoundation/Session/Storage/Handler/LegacyPdoSessionHandler.php +++ b/src/Symfony/Component/HttpFoundation/Session/Storage/Handler/LegacyPdoSessionHandler.php @@ -76,6 +76,9 @@ public function __construct(\PDO $pdo, array $dbOptions = array()) if (\PDO::ERRMODE_EXCEPTION !== $pdo->getAttribute(\PDO::ATTR_ERRMODE)) { throw new \InvalidArgumentException(sprintf('"%s" requires PDO error mode attribute be set to throw Exceptions (i.e. $pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION))', __CLASS__)); } + + trigger_error('"Symfony\Component\HttpFoundation\Session\Storage\Handler\LegacyPdoSessionHandler" is deprecated since version 2.6 and will be removed in 3.0. Use "Symfony\Component\HttpFoundation\Session\Storage\Handler\PdoSessionHandler" instead.', E_USER_DEPRECATED); + $this->pdo = $pdo; $dbOptions = array_merge(array( 'db_id_col' => 'sess_id', pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy