aboutsummaryrefslogtreecommitdiffstats
path: root/mod/receive.php
diff options
context:
space:
mode:
authorFabio Comuni <fabrix.xm@gmail.com>2011-08-30 11:00:23 +0200
committerFabio Comuni <fabrix.xm@gmail.com>2011-08-30 11:00:23 +0200
commitd0926240a87327a7e38b822802ac192336f68791 (patch)
tree49c5d2eec9954efbe313e7130e1ce970a56c60e9 /mod/receive.php
parent97806544bcd7ee3831ffc515062afe0812828b76 (diff)
parent0f1bc6e9571e367b37246e43ce08921bf317fa7c (diff)
downloadvolse-hubzilla-d0926240a87327a7e38b822802ac192336f68791.tar.gz
volse-hubzilla-d0926240a87327a7e38b822802ac192336f68791.tar.bz2
volse-hubzilla-d0926240a87327a7e38b822802ac192336f68791.zip
Merge remote-tracking branch 'friendika/master' into newui
Diffstat (limited to 'mod/receive.php')
-rw-r--r--mod/receive.php26
1 files changed, 1 insertions, 25 deletions
diff --git a/mod/receive.php b/mod/receive.php
index c3738c143..34128518b 100644
--- a/mod/receive.php
+++ b/mod/receive.php
@@ -15,8 +15,6 @@ function receive_post(&$a) {
if($a->argc != 3 || $a->argv[1] !== 'users')
http_status_exit(500);
- logger('receive: raw input: ' . file_get_contents('php://input'), LOGGER_DATA);
-
$guid = $a->argv[2];
$r = q("SELECT * FROM `user` WHERE `guid` = '%s' LIMIT 1",
@@ -43,29 +41,7 @@ function receive_post(&$a) {
if(! is_array($msg))
http_status_exit(500);
-
- $parsed_xml = parse_xml_string($msg['message'],false);
-
- $xmlbase = $parsed_xml->post;
-
- if($xmlbase->request) {
- diaspora_request($importer,$xmlbase->request);
- }
- elseif($xmlbase->status_message) {
- diaspora_post($importer,$xmlbase->status_message);
- }
- elseif($xmlbase->comment) {
- diaspora_comment($importer,$xmlbase->comment,$msg);
- }
- elseif($xmlbase->like) {
- diaspora_like($importer,$xmlbase->like,$msg);
- }
- elseif($xmlbase->retraction) {
- diaspora_retraction($importer,$xmlbase->retraction,$msg);
- }
- else {
- logger('mod-diaspora: unknown message type: ' . print_r($xmlbase,true));
- }
+ diaspora_dispatch($importer,$msg);
http_status_exit(200);
// NOTREACHED