Can someone explain to me what's the point of this function?/**
* Normalize data key
*
* Used to transform data key into the necessary
* key format for this set. Used in subclasses
* like \Slim\Http\Headers.
*
* @param string $key The data key
* @return mixed The transformed/normalized data key
*/
protected function normalizeKey($key)
{
return $key;
}
Also, PHP hate thread
>>52013430
>Used to transform data key into the necessary
>* key format for this set. Used in subclasses
>* like \Slim\Http\Headers.
>*
>* @param string $key The data key
>* @return mixed The transformed/normalized data key
can't you read? get a load of this n00b haha
>>52013430
It's clearly a draft, you fgt. Also, fuck php and all the dynamic typing languages that don't offer the option to specify variabls' type at the instantiation. May they all die in a fire.
It may have had a purpose before and was changed and it was easier to change the inside of the function than every place it was called, though the comment should have been updated to match. Or it's a placeholder.
identity function, common in functional programming
there are probably places where you pass callbacks and this is the default or something
>>52013560
who is this semen demon?
>>52013519
Look at Mr. Obvious here.
Have you read the function itself.. It doesn't alter the $key in any way, it just returns it as it is passed to the function. It does literally nothing.
>>52013430
The point is you are a shitposter and a faggot of course.
>https://github.com/slimphp/Slim/blob/3.x/Slim/Http/Headers.php#L177
Looks like a stub
>>52013674
This is from 2.x, not from 3.x
>>52013560
she is adorable :3 i'd love to do nasty things to her
I don't know PHP, but possibly overridden in subclasses or something so they can conform to different formats/interfaces?
>>52013692
Not my problem. No link was posted.
>>52013720
I searched through all branches and tags in a repo and it is simillar to what you linked.
I probably accidentally deleted a piece of code in my local fork.
Also this fixes a "bug" I've been trying to fix last 4 days. Thanks anon..
>>52013527
>don't offer the option to specify variabls' type at the instantiation. May they all die in a fire.
I am sad because c++ doesn't allow me to switch the datatype whenever the fuck I want.$kek=1;
$kek.=" LOL"
echo $kek; //"1 LOL"
$lol=intval($kek);
$lol+=1;
echo $lol; // 2
>>52013788
Damn forgot the semikolon on the end of line 2
>>52013788
>>52013634
The users are expected to override the method in children classes.
PHP does not have an override keyword (yet?)