1
0
Fork 0

Clean up the Diaspora connectivity:

- Move Diaspora code into separate functions to make it more modular
- Create more checks for whether Diaspora connectivity has been enabled
This commit is contained in:
Zach Prezkuta 2012-06-09 18:39:21 -06:00
commit 8bb7ab88fb
5 changed files with 216 additions and 129 deletions

View file

@ -492,6 +492,9 @@ function delivery_run($argv, $argc){
break;
case NETWORK_DIASPORA :
if(get_config('system','dfrn_only') || (! get_config('system','diaspora_enabled')) || (! $normal_mode))
break;
if($public_message)
$loc = 'public batch ' . $contact['batch'];
else
@ -499,9 +502,6 @@ function delivery_run($argv, $argc){
logger('delivery: diaspora batch deliver: ' . $loc);
if(get_config('system','dfrn_only') || (! get_config('system','diaspora_enabled')) || (! $normal_mode))
break;
if((! $contact['pubkey']) && (! $public_message))
break;