@@ -64,7 +64,7 @@ public function loadTokenBySeries($series)
64
64
$ sql = 'SELECT class, username, value, lastUsed AS last_used '
65
65
.' FROM rememberme_token WHERE series=:series ' ;
66
66
$ paramValues = ['series ' => $ series ];
67
- $ paramTypes = ['series ' => class_exists ( ParameterType::class) ? ParameterType:: STRING : \ PDO :: PARAM_STR ];
67
+ $ paramTypes = ['series ' => ParameterType::STRING ];
68
68
$ stmt = $ this ->conn ->executeQuery ($ sql , $ paramValues , $ paramTypes );
69
69
$ row = $ stmt instanceof Result || $ stmt instanceof DriverResult ? $ stmt ->fetchAssociative () : $ stmt ->fetch (\PDO ::FETCH_ASSOC );
70
70
@@ -82,7 +82,7 @@ public function deleteTokenBySeries($series)
82
82
{
83
83
$ sql = 'DELETE FROM rememberme_token WHERE series=:series ' ;
84
84
$ paramValues = ['series ' => $ series ];
85
- $ paramTypes = ['series ' => class_exists ( ParameterType::class) ? ParameterType:: STRING : \ PDO :: PARAM_STR ];
85
+ $ paramTypes = ['series ' => ParameterType::STRING ];
86
86
if (method_exists ($ this ->conn , 'executeStatement ' )) {
87
87
$ this ->conn ->executeStatement ($ sql , $ paramValues , $ paramTypes );
88
88
} else {
@@ -103,9 +103,9 @@ public function updateToken($series, $tokenValue, \DateTime $lastUsed)
103
103
'series ' => $ series ,
104
104
];
105
105
$ paramTypes = [
106
- 'value ' => class_exists ( ParameterType::class) ? ParameterType:: STRING : \ PDO :: PARAM_STR ,
106
+ 'value ' => ParameterType::STRING ,
107
107
'lastUsed ' => self ::$ useDeprecatedConstants ? Type::DATETIME : Types::DATETIME_MUTABLE ,
108
- 'series ' => class_exists ( ParameterType::class) ? ParameterType:: STRING : \ PDO :: PARAM_STR ,
108
+ 'series ' => ParameterType::STRING ,
109
109
];
110
110
if (method_exists ($ this ->conn , 'executeStatement ' )) {
111
111
$ updated = $ this ->conn ->executeStatement ($ sql , $ paramValues , $ paramTypes );
@@ -133,10 +133,10 @@ public function createNewToken(PersistentTokenInterface $token)
133
133
'lastUsed ' => $ token ->getLastUsed (),
134
134
];
135
135
$ paramTypes = [
136
- 'class ' => class_exists ( ParameterType::class) ? ParameterType:: STRING : \ PDO :: PARAM_STR ,
137
- 'username ' => class_exists ( ParameterType::class) ? ParameterType:: STRING : \ PDO :: PARAM_STR ,
138
- 'series ' => class_exists ( ParameterType::class) ? ParameterType:: STRING : \ PDO :: PARAM_STR ,
139
- 'value ' => class_exists ( ParameterType::class) ? ParameterType:: STRING : \ PDO :: PARAM_STR ,
136
+ 'class ' => ParameterType::STRING ,
137
+ 'username ' => ParameterType::STRING ,
138
+ 'series ' => ParameterType::STRING ,
139
+ 'value ' => ParameterType::STRING ,
140
140
'lastUsed ' => self ::$ useDeprecatedConstants ? Type::DATETIME : Types::DATETIME_MUTABLE ,
141
141
];
142
142
if (method_exists ($ this ->conn , 'executeStatement ' )) {
0 commit comments