forked from GNUsocial/gnu-social
Merge branch 'testing' of gitorious.org:statusnet/mainline into 0.9.x
Conflicts: locale/ca/LC_MESSAGES/statusnet.po locale/de/LC_MESSAGES/statusnet.po locale/statusnet.pot
This commit is contained in:
commit
e05415f621
29
README
29
README
@ -3,7 +3,7 @@ README
|
||||
------
|
||||
|
||||
StatusNet 0.9.2 ("King of Birds")
|
||||
21 Apr 2010
|
||||
3 May 2010
|
||||
|
||||
This is the README file for StatusNet, the Open Source microblogging
|
||||
platform. It includes installation instructions, descriptions of
|
||||
@ -85,18 +85,27 @@ public sites upgrade to the new version immediately.
|
||||
|
||||
Notable changes this version:
|
||||
|
||||
- Installer no longer fails with a PHP fatal error when trying to set up the
|
||||
subscription to update@status.net
|
||||
- Fixed email notifications for @-replies that come in via OStatus
|
||||
- OStatus related Fixes to the cloudy theme
|
||||
- Pass geo locations over Twitter bridge (will only be used if enabled on the Twitter side)
|
||||
- scripts/showplugins.php - script to dump the list of activated plugins and their settings
|
||||
- scripts/fixup_blocks.php - script to finds any stray subscriptions in violation of blocks, and removes them
|
||||
- Allow blocking someone who's not currently subscribed to you (prevents seeing @-replies from them, or them subbing to you in future)
|
||||
- Default 2-second timeout on Geonames web service lookups
|
||||
- OStatus related Fixes to the cloudy theme
|
||||
- Pass geo locations over Twitter bridge (will only be used if enabled on the
|
||||
Twitter side)
|
||||
- scripts/showplugins.php - script to dump the list of activated plugins and
|
||||
their settings
|
||||
- scripts/fixup_blocks.php - script to finds any stray subscriptions in
|
||||
violation of blocks, and removes them
|
||||
- Allow blocking someone who's not currently subscribed to you (prevents
|
||||
seeing @-replies from them, or them subbing to you in future)
|
||||
- Default 2-second timeout on Geonames web service lookups
|
||||
- Improved localization for plugins
|
||||
- New anti-spam measures: added nofollow rels to group members list, subscribers list
|
||||
- Shared cache key option for Geonames plugin (lets multi-instance sites share their cached geoname lookups)
|
||||
- New anti-spam measures: added nofollow rels to group members list,
|
||||
subscribers list
|
||||
- Shared cache key option for Geonames plugin (lets multi-instance sites
|
||||
share their cached geoname lookups)
|
||||
- Stability fixes to the TwitterStatusFetcher
|
||||
- If user allows location sharing but turned off browser location use profile location
|
||||
- If user allows location sharing but turned off browser location use profile
|
||||
location
|
||||
- Improved group listing via the API
|
||||
- Improved FOAF output
|
||||
- Several other bugfixes
|
||||
|
@ -185,17 +185,23 @@ class ApiTimelineFavoritesAction extends ApiBareAuthAction
|
||||
{
|
||||
$notices = array();
|
||||
|
||||
common_debug("since id = " . $this->since_id . " max id = " . $this->max_id);
|
||||
|
||||
if (!empty($this->auth_user) && $this->auth_user->id == $this->user->id) {
|
||||
$notice = $this->user->favoriteNotices(
|
||||
true,
|
||||
($this->page-1) * $this->count,
|
||||
$this->count,
|
||||
true
|
||||
$this->since_id,
|
||||
$this->max_id
|
||||
);
|
||||
} else {
|
||||
$notice = $this->user->favoriteNotices(
|
||||
false,
|
||||
($this->page-1) * $this->count,
|
||||
$this->count,
|
||||
false
|
||||
$this->since_id,
|
||||
$this->max_id
|
||||
);
|
||||
}
|
||||
|
||||
|
@ -89,7 +89,7 @@ class FavoritesrssAction extends Rss10Action
|
||||
function getNotices($limit=0)
|
||||
{
|
||||
$user = $this->user;
|
||||
$notice = $user->favoriteNotices(0, $limit);
|
||||
$notice = $user->favoriteNotices(false, 0, $limit);
|
||||
$notices = array();
|
||||
while ($notice->fetch()) {
|
||||
$notices[] = clone($notice);
|
||||
|
@ -121,11 +121,11 @@ class ShowfavoritesAction extends OwnerDesignAction
|
||||
// Show imported/gateway notices as well as local if
|
||||
// the user is looking at his own favorites
|
||||
|
||||
$this->notice = $this->user->favoriteNotices(($this->page-1)*NOTICES_PER_PAGE,
|
||||
NOTICES_PER_PAGE + 1, true);
|
||||
$this->notice = $this->user->favoriteNotices(true, ($this->page-1)*NOTICES_PER_PAGE,
|
||||
NOTICES_PER_PAGE + 1);
|
||||
} else {
|
||||
$this->notice = $this->user->favoriteNotices(($this->page-1)*NOTICES_PER_PAGE,
|
||||
NOTICES_PER_PAGE + 1, false);
|
||||
$this->notice = $this->user->favoriteNotices(false, ($this->page-1)*NOTICES_PER_PAGE,
|
||||
NOTICES_PER_PAGE + 1);
|
||||
}
|
||||
|
||||
if (empty($this->notice)) {
|
||||
|
@ -75,13 +75,13 @@ class Fave extends Memcached_DataObject
|
||||
return Memcached_DataObject::pkeyGet('Fave', $kv);
|
||||
}
|
||||
|
||||
function stream($user_id, $offset=0, $limit=NOTICES_PER_PAGE, $own=false)
|
||||
function stream($user_id, $offset=0, $limit=NOTICES_PER_PAGE, $own=false, $since_id=0, $max_id=0)
|
||||
{
|
||||
$ids = Notice::stream(array('Fave', '_streamDirect'),
|
||||
array($user_id, $own),
|
||||
($own) ? 'fave:ids_by_user_own:'.$user_id :
|
||||
'fave:ids_by_user:'.$user_id,
|
||||
$offset, $limit);
|
||||
$offset, $limit, $since_id, $max_id);
|
||||
return $ids;
|
||||
}
|
||||
|
||||
|
@ -464,9 +464,9 @@ class User extends Memcached_DataObject
|
||||
return $profile->getNotices($offset, $limit, $since_id, $before_id);
|
||||
}
|
||||
|
||||
function favoriteNotices($offset=0, $limit=NOTICES_PER_PAGE, $own=false)
|
||||
function favoriteNotices($own=false, $offset=0, $limit=NOTICES_PER_PAGE, $since_id=0, $max_id=0)
|
||||
{
|
||||
$ids = Fave::stream($this->id, $offset, $limit, $own);
|
||||
$ids = Fave::stream($this->id, $offset, $limit, $own, $since_id, $max_id);
|
||||
return Notice::getStreamByIds($ids);
|
||||
}
|
||||
|
||||
|
@ -188,7 +188,8 @@ $default =
|
||||
'cache' =>
|
||||
array('base' => null),
|
||||
'ping' =>
|
||||
array('notify' => array()),
|
||||
array('notify' => array(),
|
||||
'timeout' => 2),
|
||||
'inboxes' =>
|
||||
array('enabled' => true), # ignored after 0.9.x
|
||||
'newuser' =>
|
||||
|
10
lib/ping.php
10
lib/ping.php
@ -45,7 +45,15 @@ function ping_broadcast_notice($notice) {
|
||||
$tags));
|
||||
|
||||
$request = HTTPClient::start();
|
||||
$httpResponse = $request->post($notify_url, array('Content-Type: text/xml'), $req);
|
||||
$request->setConfig('connect_timeout', common_config('ping', 'timeout'));
|
||||
$request->setConfig('timeout', common_config('ping', 'timeout'));
|
||||
try {
|
||||
$httpResponse = $request->post($notify_url, array('Content-Type: text/xml'), $req);
|
||||
} catch (Exception $e) {
|
||||
common_log(LOG_ERR,
|
||||
"Exception pinging $notify_url: " . $e->getMessage());
|
||||
continue;
|
||||
}
|
||||
|
||||
if (!$httpResponse || mb_strlen($httpResponse->getBody()) == 0) {
|
||||
common_log(LOG_WARNING,
|
||||
|
@ -253,12 +253,12 @@ class XmppManager extends IoManager
|
||||
$from = jabber_normalize_jid($pl['from']);
|
||||
|
||||
if ($pl['type'] != 'chat') {
|
||||
$this->log(LOG_WARNING, "Ignoring message of type ".$pl['type']." from $from.");
|
||||
$this->log(LOG_WARNING, "Ignoring message of type ".$pl['type']." from $from: " . $pl['xml']->toString());
|
||||
return;
|
||||
}
|
||||
|
||||
if (mb_strlen($pl['body']) == 0) {
|
||||
$this->log(LOG_WARNING, "Ignoring message with empty body from $from.");
|
||||
$this->log(LOG_WARNING, "Ignoring message with empty body from $from: " . $pl['xml']->toString());
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -38,7 +38,7 @@ class DirectionDetectorPlugin extends Plugin {
|
||||
* @param object $notice notice is going to be saved
|
||||
*/
|
||||
public function onStartNoticeSave(&$notice){
|
||||
if(self::isRTL($notice->content))
|
||||
if(!preg_match('/<span class="rtl">/', $notice->rendered) && self::isRTL($notice->content))
|
||||
$notice->rendered = '<span class="rtl">'.$notice->rendered.'</span>';
|
||||
return true;
|
||||
}
|
||||
@ -48,7 +48,7 @@ class DirectionDetectorPlugin extends Plugin {
|
||||
*
|
||||
* @param
|
||||
*/
|
||||
public function onEndShowStatusNetStyles(&$xml){
|
||||
public function onEndShowStatusNetStyles($xml){
|
||||
$xml->element('style', array('type' => 'text/css'), 'span.rtl {display:block;direction:rtl;text-align:right;float:right;width:490px;} .notice .author {float:left}');
|
||||
}
|
||||
/**
|
||||
@ -102,7 +102,7 @@ class DirectionDetectorPlugin extends Plugin {
|
||||
*
|
||||
* Returns false if the input string isn't a valid UTF-8 octet sequence.
|
||||
*/
|
||||
private static function utf8ToUnicode(&$str){
|
||||
private static function utf8ToUnicode($str){
|
||||
$mState = 0; // cached expected number of octets after the current octet
|
||||
// until the beginning of the next UTF8 character sequence
|
||||
$mUcs4 = 0; // cached Unicode character
|
||||
|
@ -104,7 +104,7 @@ class FeedDiscovery
|
||||
$response = $client->get($url);
|
||||
} catch (HTTP_Request2_Exception $e) {
|
||||
common_log(LOG_ERR, __METHOD__ . " Failure for $url - " . $e->getMessage());
|
||||
throw new FeedSubBadURLException($e);
|
||||
throw new FeedSubBadURLException($e->getMessage());
|
||||
}
|
||||
|
||||
if ($htmlOk) {
|
||||
|
Loading…
Reference in New Issue
Block a user