Skip to content

Commit

Permalink
#15598 - Implement __serialize() and __unserialize() methods
Browse files Browse the repository at this point in the history
  • Loading branch information
Jeckerson committed May 29, 2022
1 parent 0e8a4e1 commit 83f2ed6
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion phalcon/Storage/Serializer/AbstractSerializer.zep
Original file line number Diff line number Diff line change
Expand Up @@ -81,11 +81,16 @@ abstract class AbstractSerializer implements SerializerInterface

public function __serialize() -> array
{
var_dump(this->data);
if typeof this->data === "array" {
return this->data;
}

return [];
}

public function __unserialize(array data) -> void
{
// Nothing here
let this->data = data;
}
}

0 comments on commit 83f2ed6

Please sign in to comment.