added curly braces/spaces + replace spaces with tabs to fix code indending (or so?)

Signed-off-by: Roland Haeder <roland@mxchange.org>
This commit is contained in:
Roland Häder 2016-12-21 23:04:09 +01:00
commit d3e666f71a
No known key found for this signature in database
GPG key ID: B72F8185C6C7BD78
7 changed files with 88 additions and 91 deletions

View file

@ -56,10 +56,11 @@ function follow_content(App &$a) {
// NOTREACHED
}
if ($ret["network"] == NETWORK_MAIL)
if ($ret["network"] == NETWORK_MAIL) {
$ret["url"] = $ret["addr"];
}
if($ret['network'] === NETWORK_DFRN) {
if ($ret['network'] === NETWORK_DFRN) {
$request = $ret["request"];
$tpl = get_markup_template('dfrn_request.tpl');
} else {
@ -84,20 +85,22 @@ function follow_content(App &$a) {
$r = q("SELECT `id`, `location`, `about`, `keywords` FROM `gcontact` WHERE `nurl` = '%s'",
normalise_link($ret["url"]));
if (!$r)
if (!$r) {
$r = array(array("location" => "", "about" => "", "keywords" => ""));
else
} else {
$gcontact_id = $r[0]["id"];
}
if($ret['network'] === NETWORK_DIASPORA) {
if ($ret['network'] === NETWORK_DIASPORA) {
$r[0]["location"] = "";
$r[0]["about"] = "";
}
$header = $ret["name"];
if ($ret["addr"] != "")
if ($ret["addr"] != "") {
$header .= " <".$ret["addr"].">";
}
//$header .= " (".network_to_name($ret['network'], $ret['url']).")";
$header = t("Connect/Follow");
@ -176,8 +179,7 @@ function follow_post(App &$a) {
notice($result['message']);
}
goaway($return_url);
}
elseif ($result['cid']) {
} elseif ($result['cid']) {
goaway(App::get_baseurl().'/contacts/'.$result['cid']);
}