aboutsummaryrefslogtreecommitdiffstats
path: root/mod/receive.php
diff options
context:
space:
mode:
authorFriendika <info@friendika.com>2011-08-24 01:21:24 -0700
committerFriendika <info@friendika.com>2011-08-24 01:21:24 -0700
commit2aa23843e401e7f448c3d12f844934da6c27f8ef (patch)
treef36ffd56669d32b1ace2034ceb0cb3a3178a6f7d /mod/receive.php
parent2cfdcee29a80e355307d013fe71d23a7300f8d98 (diff)
downloadvolse-hubzilla-2aa23843e401e7f448c3d12f844934da6c27f8ef.tar.gz
volse-hubzilla-2aa23843e401e7f448c3d12f844934da6c27f8ef.tar.bz2
volse-hubzilla-2aa23843e401e7f448c3d12f844934da6c27f8ef.zip
D* queue
Diffstat (limited to 'mod/receive.php')
-rw-r--r--mod/receive.php29
1 files changed, 1 insertions, 28 deletions
diff --git a/mod/receive.php b/mod/receive.php
index b50774933..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,32 +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);
- }
- elseif($xmlbase->photo) {
- diaspora_photo($importer,$xmlbase->photo,$msg);
- }
- else {
- logger('mod-diaspora: unknown message type: ' . print_r($xmlbase,true));
- }
+ diaspora_dispatch($importer,$msg);
http_status_exit(200);
// NOTREACHED