setting in_reply_to_profileurl with exception handling
This commit is contained in:
parent
8443b37035
commit
18877f77f0
|
@ -462,13 +462,11 @@ class QvitterPlugin extends Plugin {
|
||||||
}
|
}
|
||||||
|
|
||||||
// reply-to profile url
|
// reply-to profile url
|
||||||
|
try {
|
||||||
|
$reply = $notice->getParent();
|
||||||
|
$twitter_status['in_reply_to_profileurl'] = $reply->getProfile()->getUrl();
|
||||||
|
} catch (ServerException $e) {
|
||||||
$twitter_status['in_reply_to_profileurl'] = null;
|
$twitter_status['in_reply_to_profileurl'] = null;
|
||||||
if ($notice->reply_to) {
|
|
||||||
$reply = Notice::getKV(intval($notice->reply_to));
|
|
||||||
if ($reply) {
|
|
||||||
$replier_profile = $reply->getProfile();
|
|
||||||
$twitter_status['in_reply_to_profileurl'] = $replier_profile->profileurl;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user