summaryrefslogtreecommitdiff
path: root/actions/finishremotesubscribe.php
diff options
context:
space:
mode:
Diffstat (limited to 'actions/finishremotesubscribe.php')
-rw-r--r--actions/finishremotesubscribe.php8
1 files changed, 7 insertions, 1 deletions
diff --git a/actions/finishremotesubscribe.php b/actions/finishremotesubscribe.php
index 41bc91afd..fa9aa539f 100644
--- a/actions/finishremotesubscribe.php
+++ b/actions/finishremotesubscribe.php
@@ -140,7 +140,7 @@ class FinishremotesubscribeAction extends Action {
}
if ($avatar_url) {
- $this->add_avatar($avatar_url);
+ $this->add_avatar($profile, $avatar_url);
}
$remote->postnoticeurl = $omb[OMB_ENDPOINT_POSTNOTICE];
@@ -175,6 +175,12 @@ class FinishremotesubscribeAction extends Action {
$user->nickname)));
}
+ function add_avatar($profile, $url) {
+ $temp_filename = tempnam(sys_get_temp_dir(), 'listener_avatar');
+ copy($url, $temp_filename);
+ return $profile->setOriginal($temp_filename);
+ }
+
function access_token($omb) {
$con = omb_oauth_consumer();