]> git.mxchange.org Git - friendica-addons.git/commitdiff
SN apply debugging info to the log as for Twitter
authorTobias Diekershoff <tobias.diekershoff@gmx.net>
Tue, 15 May 2012 08:54:48 +0000 (10:54 +0200)
committerTobias Diekershoff <tobias.diekershoff@gmx.net>
Tue, 15 May 2012 08:54:48 +0000 (10:54 +0200)
statusnet/statusnet.php

index 469b3ab89e9d4ee44c9884be6b7407ee1deed24d..3b1899329e613700e73acdabed1e11760b08692d 100755 (executable)
@@ -489,9 +489,14 @@ function statusnet_post_hook(&$a,&$b) {
                         $msg = implode(' ', $e);
                        $msg .= '... ' . $shortlink;
                }
-               // and now tweet it :-)
-               if(strlen($msg))
-                       $dent->post('statuses/update', array('status' => $msg));
+               // and now dent it :-)
+               if(strlen($msg)) {
+                    $result = $dent->post('statuses/update', array('status' => $msg));
+                    logger('statusnet_post send, result: ' . print_r($result, true), LOGGER_DEBUG);
+                    if ($result->error) {
+                        logger('Send to StatusNet failed: "' . $result->error . '"');
+                    }
+                }
        }
 }