]> git.mxchange.org Git - friendica.git/commitdiff
Merge remote branch 'upstream/master'
authorMichael Vogel <icarus@dabo.de>
Mon, 4 Jun 2012 06:09:15 +0000 (08:09 +0200)
committerMichael Vogel <icarus@dabo.de>
Mon, 4 Jun 2012 06:09:15 +0000 (08:09 +0200)
1  2 
include/api.php

diff --combined include/api.php
index cd8526f89564e64e6a221edebd3bccd126196243,5c17b35f56e7ae25b64631b653e966f3523dae75..9925b57663a9a00f01c2ed759df7399e9dfec098
                // params
                $id = intval($a->argv[3]);
  
 -              logger('API: api_statuses_repeat: '.$id);               
 +              logger('API: api_statuses_repeat: '.$id);
  
                //$include_entities = (x($_REQUEST,'include_entities')?$_REQUEST['include_entities']:false);
  
                        intval($id)
                );
  
 -              $_REQUEST['body'] = html_entity_decode("&#x2672; ", ENT_QUOTES, 'UTF-8')."[url=".$r[0]['reply_url']."]".$r[0]['reply_author']."[/url] \n".$r[0]['body'];
 -              $_REQUEST['profile_uid'] = local_user();
 -              $_REQUEST['type'] = 'wall';
 -              $_REQUEST['api_source'] = true;
 +              if ($r[0]['body'] != "") {
 +                      $_REQUEST['body'] = html_entity_decode("&#x2672; ", ENT_QUOTES, 'UTF-8')."[url=".$r[0]['reply_url']."]".$r[0]['reply_author']."[/url] \n".$r[0]['body'];
 +                      $_REQUEST['profile_uid'] = local_user();
 +                      $_REQUEST['type'] = 'wall';
 +                      $_REQUEST['api_source'] = true;
  
 -              require_once('mod/item.php');
 -              item_post($a);
 +                      require_once('mod/item.php');
 +                      item_post($a);
 +              }
  
                if ($type == 'xml')
                        $ok = "true";
                // params
                $id = intval($a->argv[3]);
  
 -              logger('API: api_statuses_destroy: '.$id);      
 +              logger('API: api_statuses_destroy: '.$id);
  
                require_once('include/items.php');
                drop_item($id, false);
                  else
                          $sql_extra .= sprintf(" AND `item`.`parent` IN (SELECT distinct(`parent`) from item where ( `author-link` like '%s' or `tag` like '%s' or tag like '%s' )) ",
                                  dbesc(protect_sprintf('%' . $myurl)),
-                                 dbesc(protect_sprintf('%' . $myurl . '\\]%')),
-                                 dbesc(protect_sprintf('%' . $diasp_url . '\\]%'))
+                                 dbesc(protect_sprintf('%' . $myurl . ']%')),
+                                 dbesc(protect_sprintf('%' . $diasp_url . ']%'))
                          );
  
                if ($max_id > 0)