mirror of
https://git.friendi.ca/friendica/friendica.git
synced 2025-06-17 00:45:14 +02:00
Merge remote-tracking branch 'upstream/master'
This commit is contained in:
commit
e67062d9cf
59 changed files with 2319 additions and 1673 deletions
|
@ -590,6 +590,12 @@ function probe_url($url, $mode = PROBE_NORMAL) {
|
|||
|
||||
$check_feed = false;
|
||||
|
||||
if(stristr($url,'tumblr.com') && (! stristr($url,'/rss'))) {
|
||||
$poll = $url . '/rss';
|
||||
$check_feed = true;
|
||||
// Will leave it to others to figure out how to grab the avatar, which is on the $url page in the open graph meta links
|
||||
}
|
||||
|
||||
if($twitter || ! $poll)
|
||||
$check_feed = true;
|
||||
if((! isset($vcard)) || (! x($vcard,'fn')) || (! $profile))
|
||||
|
|
|
@ -165,6 +165,7 @@ function send_wallmessage($recipient='', $body='', $subject='', $replyto=''){
|
|||
|
||||
$a = get_app();
|
||||
|
||||
|
||||
if(! $recipient) return -1;
|
||||
|
||||
if(! strlen($subject))
|
||||
|
@ -195,7 +196,7 @@ function send_wallmessage($recipient='', $body='', $subject='', $replyto=''){
|
|||
$handles = $recip_handle . ';' . $sender_handle;
|
||||
|
||||
$r = q("insert into conv (uid,guid,creator,created,updated,subject,recips) values(%d, '%s', '%s', '%s', '%s', '%s', '%s') ",
|
||||
intval(local_user()),
|
||||
intval($recipient['uid']),
|
||||
dbesc($conv_guid),
|
||||
dbesc($sender_handle),
|
||||
dbesc(datetime_convert()),
|
||||
|
|
|
@ -336,11 +336,18 @@ function sanitise_acl(&$item) {
|
|||
|
||||
|
||||
// Convert an ACL array to a storable string
|
||||
// Normally ACL permissions will be an array.
|
||||
// We'll also allow a comma-separated string.
|
||||
|
||||
if(! function_exists('perms2str')) {
|
||||
function perms2str($p) {
|
||||
$ret = '';
|
||||
$tmp = $p;
|
||||
|
||||
if(is_array($p))
|
||||
$tmp = $p;
|
||||
else
|
||||
$tmp = explode(',',$p);
|
||||
|
||||
if(is_array($tmp)) {
|
||||
array_walk($tmp,'sanitise_acl');
|
||||
$ret = implode('',$tmp);
|
||||
|
|
|
@ -73,6 +73,18 @@ function import_account(&$a, $file) {
|
|||
return;
|
||||
}
|
||||
|
||||
|
||||
// check for username
|
||||
$r = q("SELECT uid FROM user WHERE nickname='%s'", $account['user']['nickname']);
|
||||
if ($r===false) {
|
||||
logger("uimport:check nickname : ERROR : ".last_error(), LOGGER_NORMAL);
|
||||
notice(t('Error! Cannot check nickname'));
|
||||
return;
|
||||
}
|
||||
if (count($r)>0) {
|
||||
notice(sprintf(t("User '%s' already exists on this server!"),$account['user']['nickname']));
|
||||
return;
|
||||
}
|
||||
|
||||
$oldbaseurl = $account['baseurl'];
|
||||
$newbaseurl = $a->get_baseurl();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue