Fix: prevent user serialization for SocialActivity

This commit is contained in:
buddh4 2018-07-19 14:02:23 +02:00
parent 5658832972
commit 7dc40c862c
2 changed files with 7 additions and 2 deletions

View File

@ -374,7 +374,7 @@ abstract class SocialActivity extends \yii\base\BaseObject implements rendering\
{
return serialize([
'source' => $this->source,
'originator' => $this->originator
'originator_id' => $this->originator->id
]);
}
@ -389,7 +389,7 @@ abstract class SocialActivity extends \yii\base\BaseObject implements rendering\
{
$this->init();
$unserializedArr = unserialize($serialized);
$this->from($unserializedArr['originator']);
$this->from(User::findOne(['id' => $unserializedArr['originator_id']]));
$this->about($unserializedArr['source']);
}
}

View File

@ -1,6 +1,10 @@
HumHub Change Log
=================
1.3.0-beta.3
-----------------------------
- Fix: prevent user serialization for SocialActivity
1.3.0-beta.2 (July 18, 2018)
-----------------------------
@ -50,6 +54,7 @@ Please read the [Update Guide](http://docs.humhub.org/beta/admin-updating-130.ht
- Enh: Removed built and compressed assets from GitHub sources
1.3.0-beta.1 (July 4, 2018)
----------------------------