mirror of
https://github.com/friendica/friendica
synced 2025-04-19 06:30:10 +00:00
Remove unused code in mod/
- Remove commented code - Remove unused/immediately overwritten variables - Remove extraneous parameters - Remove unreachable code
This commit is contained in:
parent
4a95ca280d
commit
dbc6eb5422
34 changed files with 32 additions and 173 deletions
|
@ -188,7 +188,7 @@ function dfrn_request_post(App $a)
|
|||
}
|
||||
|
||||
if (strlen($dfrn_request) && strlen($confirm_key)) {
|
||||
$s = Network::fetchUrl($dfrn_request . '?confirm_key=' . $confirm_key);
|
||||
Network::fetchUrl($dfrn_request . '?confirm_key=' . $confirm_key);
|
||||
}
|
||||
|
||||
// (ignore reply, nothing we can do it failed)
|
||||
|
@ -230,7 +230,6 @@ function dfrn_request_post(App $a)
|
|||
}
|
||||
|
||||
$nickname = $a->profile['nickname'];
|
||||
$notify_flags = $a->profile['notify-flags'];
|
||||
$uid = $a->profile['uid'];
|
||||
$maxreq = intval($a->profile['maxreq']);
|
||||
$contact_record = null;
|
||||
|
@ -271,8 +270,6 @@ function dfrn_request_post(App $a)
|
|||
}
|
||||
}
|
||||
|
||||
$real_name = !empty($_POST['realname']) ? Strings::escapeTags(trim($_POST['realname'])) : '';
|
||||
|
||||
$url = trim($_POST['dfrn_url']);
|
||||
if (!strlen($url)) {
|
||||
notice(L10n::t("Invalid locator") . EOL);
|
||||
|
@ -420,7 +417,7 @@ function dfrn_request_post(App $a)
|
|||
$hash = Strings::getRandomHex() . (string) time(); // Generate a confirm_key
|
||||
|
||||
if (is_array($contact_record)) {
|
||||
$ret = q("INSERT INTO `intro` ( `uid`, `contact-id`, `blocked`, `knowyou`, `note`, `hash`, `datetime`)
|
||||
q("INSERT INTO `intro` ( `uid`, `contact-id`, `blocked`, `knowyou`, `note`, `hash`, `datetime`)
|
||||
VALUES ( %d, %d, 1, %d, '%s', '%s', '%s' )",
|
||||
intval($uid),
|
||||
intval($contact_record['id']),
|
||||
|
@ -586,7 +583,7 @@ function dfrn_request_content(App $a)
|
|||
// If we are auto_confirming, this record will have already been nuked
|
||||
// in dfrn_confirm_post()
|
||||
|
||||
$r = q("UPDATE `intro` SET `blocked` = 0 WHERE `hash` = '%s'",
|
||||
q("UPDATE `intro` SET `blocked` = 0 WHERE `hash` = '%s'",
|
||||
DBA::escape($_GET['confirm_key'])
|
||||
);
|
||||
}
|
||||
|
@ -657,6 +654,4 @@ function dfrn_request_content(App $a)
|
|||
]);
|
||||
return $o;
|
||||
}
|
||||
|
||||
return; // Somebody is fishing.
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue