]> git.mxchange.org Git - friendica.git/blobdiff - include/dfrn.php
Opps ...
[friendica.git] / include / dfrn.php
index 0c88d22c4bee35f35f1ed5e0eb8ef42e537f88fd..7d5020425b26380e37c9eb43b0b10be0f1468b63 100644 (file)
@@ -870,7 +870,7 @@ class dfrn {
 
                // The signed text contains the content in Markdown, the sender handle and the signatur for the content
                // It is needed for relayed comments to Diaspora.
-               if($item['signed_text']) {
+               if ($item['signed_text']) {
                        $sign = base64_encode(json_encode(array('signed_text' => $item['signed_text'],'signature' => $item['signature'],'signer' => $item['signer'])));
                        xml::add_element($doc, $entry, "dfrn:diaspora_signature", $sign);
                }
@@ -1277,7 +1277,7 @@ class dfrn {
                        $href = "";
                        $width = 0;
                        foreach ($avatar->attributes AS $attributes) {
-                               /// @TODO Rewrite these similar if() to one switch
+                               /// @TODO Rewrite these similar if () to one switch
                                if ($attributes->name == "href") {
                                        $href = $attributes->textContent;
                                }
@@ -1836,7 +1836,7 @@ class dfrn {
                if (edited_timestamp_is_newer($current, $item)) {
 
                        // do not accept (ignore) an earlier edit than one we currently have.
-                       if(datetime_convert("UTC","UTC",$item["edited"]) < $current["edited"])
+                       if (datetime_convert("UTC","UTC",$item["edited"]) < $current["edited"])
                                return(false);
 
                        $r = q("UPDATE `item` SET `title` = '%s', `body` = '%s', `tag` = '%s', `edited` = '%s', `changed` = '%s' WHERE `uri` = '%s' AND `uid` = %d",
@@ -1887,7 +1887,7 @@ class dfrn {
                if ($item["parent-uri"] != $item["uri"]) {
                        $community = false;
 
-                       if($importer["page-flags"] == PAGE_COMMUNITY || $importer["page-flags"] == PAGE_PRVGROUP) {
+                       if ($importer["page-flags"] == PAGE_COMMUNITY || $importer["page-flags"] == PAGE_PRVGROUP) {
                                $sql_extra = "";
                                $community = true;
                                logger("possible community action");
@@ -1974,7 +1974,7 @@ class dfrn {
                                }
                        }
 
-                       if($Blink && link_compare($Blink,App::get_baseurl()."/profile/".$importer["nickname"])) {
+                       if ($Blink && link_compare($Blink,App::get_baseurl()."/profile/".$importer["nickname"])) {
 
                                // send a notification
                                notification(array(
@@ -2043,7 +2043,7 @@ class dfrn {
                                return false;
                        }
                } else {
-                       if(($item["verb"] == ACTIVITY_LIKE)
+                       if (($item["verb"] == ACTIVITY_LIKE)
                                || ($item["verb"] == ACTIVITY_DISLIKE)
                                || ($item["verb"] == ACTIVITY_ATTEND)
                                || ($item["verb"] == ACTIVITY_ATTENDNO)
@@ -2122,7 +2122,7 @@ class dfrn {
                $title = "";
                foreach ($links AS $link) {
                        foreach ($link->attributes AS $attributes) {
-                               /// @TODO Rewrite these repeated (same) if() statements to a switch()
+                               /// @TODO Rewrite these repeated (same) if () statements to a switch()
                                if ($attributes->name == "href") {
                                        $href = $attributes->textContent;
                                }
@@ -2370,7 +2370,7 @@ class dfrn {
                        // When activated, forums don't work.
                        // And: Why should we disallow commenting by followers?
                        // the behaviour is now similar to the Diaspora part.
-                       //if($importer["rel"] == CONTACT_IS_FOLLOWER) {
+                       //if ($importer["rel"] == CONTACT_IS_FOLLOWER) {
                        //      logger("Contact ".$importer["id"]." is only follower. Quitting", LOGGER_DEBUG);
                        //      return;
                        //}
@@ -2492,7 +2492,7 @@ class dfrn {
 
                        logger("Item was stored with id ".$posted_id, LOGGER_DEBUG);
 
-                       if(stristr($item["verb"],ACTIVITY_POKE))
+                       if (stristr($item["verb"],ACTIVITY_POKE))
                                self::do_poke($item, $importer, $posted_id);
                }
        }
@@ -2594,7 +2594,7 @@ class dfrn {
                                }
                        }
 
-                       if($entrytype == DFRN_TOP_LEVEL) {
+                       if ($entrytype == DFRN_TOP_LEVEL) {
                                $r = q("UPDATE `item` SET `deleted` = 1, `edited` = '%s', `changed` = '%s',
                                                `body` = '', `title` = ''
                                        WHERE `parent-uri` = '%s' AND `uid` = %d",
@@ -2618,7 +2618,7 @@ class dfrn {
                                create_tags_from_itemuri($uri, $importer["uid"]);
                                create_files_from_itemuri($uri, $importer["uid"]);
                                update_thread_uri($uri, $importer["importer_uid"]);
-                               if($item["last-child"]) {
+                               if ($item["last-child"]) {
                                        // ensure that last-child is set in case the comment that had it just got wiped.
                                        q("UPDATE `item` SET `last-child` = 0, `changed` = '%s' WHERE `parent-uri` = '%s' AND `uid` = %d ",
                                                dbesc(datetime_convert()),
@@ -2639,7 +2639,7 @@ class dfrn {
                                }
                                // if this is a relayed delete, propagate it to other recipients
 
-                               if($entrytype == DFRN_REPLY_RC) {
+                               if ($entrytype == DFRN_REPLY_RC) {
                                        logger("Notifying followers about deletion of post ".$item["id"], LOGGER_DEBUG);
                                        proc_run(PRIORITY_HIGH, "include/notifier.php","drop", $item["id"]);
                                }
@@ -2659,7 +2659,7 @@ class dfrn {
                if ($xml == "")
                        return;
 
-               if($importer["readonly"]) {
+               if ($importer["readonly"]) {
                        // We aren't receiving stuff from this person. But we will quietly ignore them
                        // rather than a blatant "go away" message.
                        logger('ignoring contact '.$importer["id"]);