use Friendica\Core\Config;
use Friendica\Core\PConfig;
use Friendica\Model\GlobalContact;
+use Friendica\Object\Photo;
class StatusNetOAuth extends TwitterOAuth {
function get_maxlength() {
if($b['private'] || !strstr($b['postopts'],'statusnet'))
return;
+
+ // Dont't post if the post doesn't belong to us.
+ // This is a check for forum postings
+ $self = dba::select('contact', array('id'), array('uid' => $b['uid'], 'self' => true), array('limit' => 1));
+ if ($b['contact-id'] != $self['id']) {
+ return;
+ }
}
if (($b['verb'] == ACTIVITY_POST) && $b['deleted'])
group_add_member($uid,'',$contact_id,$g[0]['def_gid']);
}
- require_once("Photo.php");
-
- $photos = import_profile_photo($contact->profile_image_url,$uid,$contact_id);
+ $photos = Photo::importProfilePhoto($contact->profile_image_url,$uid,$contact_id);
q("UPDATE `contact` SET `photo` = '%s',
`thumb` = '%s',
logger("statusnet_fetch_contact: Updating contact ".$contact->screen_name, LOGGER_DEBUG);
- require_once("Photo.php");
-
- $photos = import_profile_photo($contact->profile_image_url, $uid, $r[0]['id']);
+ $photos = Photo::importProfilePhoto($contact->profile_image_url, $uid, $r[0]['id']);
q("UPDATE `contact` SET `photo` = '%s',
`thumb` = '%s',