fix reference variable effects on sorting

This commit is contained in:
friendica 2012-01-03 14:27:00 -08:00
parent 184230e068
commit c583d16209
4 changed files with 10 additions and 6 deletions

View file

@ -9,7 +9,7 @@ require_once('include/nav.php');
require_once('include/cache.php'); require_once('include/cache.php');
define ( 'FRIENDICA_PLATFORM', 'Friendica'); define ( 'FRIENDICA_PLATFORM', 'Friendica');
define ( 'FRIENDICA_VERSION', '2.3.1214' ); define ( 'FRIENDICA_VERSION', '2.3.1215' );
define ( 'DFRN_PROTOCOL_VERSION', '2.22' ); define ( 'DFRN_PROTOCOL_VERSION', '2.22' );
define ( 'DB_UPDATE_VERSION', 1114 ); define ( 'DB_UPDATE_VERSION', 1114 );

View file

@ -911,9 +911,13 @@ function conv_sort($arr,$order) {
$parents[$p]['children'][] = $x; $parents[$p]['children'][] = $x;
} }
} }
foreach($parents as $x) foreach($parents as $k => $v) {
if(count($x['children'])) if(count($parents[$k]['children'])) {
usort($x['children'],'sort_thr_created_rev'); $y = $parents[$k]['children'];
usort($y,'sort_thr_created_rev');
$parents[$k]['children'] = $y;
}
}
$ret = array(); $ret = array();
foreach($parents as $x) { foreach($parents as $x) {

View file

@ -945,7 +945,7 @@ function tgroup_deliver($uid,$item_id) {
$link = normalise_link($a->get_baseurl() . '/profile/' . $u[0]['nickname']); $link = normalise_link($a->get_baseurl() . '/profile/' . $u[0]['nickname']);
$cnt = preg_match_all('/\@\[url\=(.*?)\](.*?)\[\/url\]/ism',$item['body'],$matches,PREG_SET_ORDER); $cnt = preg_match_all('/[\@\!]\[url\=(.*?)\](.*?)\[\/url\]/ism',$item['body'],$matches,PREG_SET_ORDER);
if($cnt) { if($cnt) {
foreach($matches as $mtch) { foreach($matches as $mtch) {
if(link_compare($link,$mtch[1])) { if(link_compare($link,$mtch[1])) {

View file

@ -12,7 +12,7 @@
<id>$feed_id</id> <id>$feed_id</id>
<title>$feed_title</title> <title>$feed_title</title>
<generator uri="http://friendika.com" version="$version">Friendika</generator> <generator uri="http://friendica.com" version="$version">Friendica</generator>
<link rel="license" href="http://creativecommons.org/licenses/by/3.0/" /> <link rel="license" href="http://creativecommons.org/licenses/by/3.0/" />
$hub $hub
$salmon $salmon