added spaces + some curly braces + some usage of dbm::is_result()

Signed-off-by: Roland Häder <roland@mxchange.org>
This commit is contained in:
Roland Häder 2017-01-26 15:23:30 +01:00 committed by Roland Haeder
commit 0cd241bcbe
No known key found for this signature in database
GPG key ID: B72F8185C6C7BD78
92 changed files with 1190 additions and 1087 deletions

View file

@ -6,14 +6,15 @@ function xrd_init(App $a) {
$uri = urldecode(notags(trim($_GET['uri'])));
if(substr($uri,0,4) === 'http') {
if (substr($uri,0,4) === 'http') {
$acct = false;
$name = basename($uri);
} else {
$acct = true;
$local = str_replace('acct:', '', $uri);
if(substr($local,0,2) == '//')
if (substr($local,0,2) == '//') {
$local = substr($local,2);
}
$name = substr($local,0,strpos($local,'@'));
}