function isFacebookBound($notice, $flink) {
if (empty($flink)) {
+ common_debug("QQQQQ empty flink");
return false;
}
common_log(LOG_WARNING, $msg);
}
- // Finally, attempt to update the user's profile box
- if ($canPublish == 1 || $canUpdate == 1) {
- updateProfileBox($facebook, $flink, $notice, $user);
- }
-
} catch (FacebookRestClientException $e) {
return handleFacebookError($e, $notice, $flink);
}
);
}
-function updateProfileBox($facebook, $flink, $notice, $user) {
-
- $facebook = getFacebook();
- $fbaction = new FacebookAction(
- $output = 'php://output',
- $indent = null,
- $facebook,
- $flink
- );
-
- $fbuid = $flink->foreign_id;
-
- common_debug(
- 'FacebookPlugin - Attempting to update profile box with '
- . "content from notice $notice->id for $user->nickname ($user->id), "
- . "Facebook UID: $fbuid"
- );
-
- $fbaction->updateProfileBox($notice);
-
- common_debug(
- 'FacebookPlugin - finished updating profile box for '
- . "$user->nickname ($user->id) Facebook UID: $fbuid"
- );
-
-}
-
function format_attachments($attachments)
{
$fbattachment = array();