This should be a method definition in the class, for example:
class SomeClass { function unserialize($data) { return unserialize($data); }
Otherwise, you will receive a fatal error stating that you cannot update unserialize() .
All he does is add the unserialize() method to the class. This method then calls the built-in unserialize() function in PHP. It seems pretty dumb, but then, I did not write Wordpress.
I believe I found this method: wp-includes/rss.php (line 783). And this is really an RSSCache class RSSCache .
I suppose they might want to write their own serialization routine in the future, and / or some RSSCache subclass has its own serialize() and unserialize() .
source share