resolve conflict
This commit is contained in:
parent
2d9d4dfeb3
commit
b634c08d0e
@ -437,70 +437,14 @@ function import_post(&$a) {
|
|||||||
|
|
||||||
// FIXME - ensure we have an xchan if somebody is trying to pull a fast one
|
// FIXME - ensure we have an xchan if somebody is trying to pull a fast one
|
||||||
|
|
||||||
<<<<<<< HEAD
|
|
||||||
|
|
||||||
if($completed < 8) {
|
if($completed < 8) {
|
||||||
$friends = 0;
|
$friends = 0;
|
||||||
$feeds = 0;
|
$feeds = 0;
|
||||||
=======
|
|
||||||
|
|
||||||
$friends = 0;
|
|
||||||
$feeds = 0;
|
|
||||||
|
|
||||||
// import contacts
|
|
||||||
$abooks = $data['abook'];
|
|
||||||
if($abooks) {
|
|
||||||
foreach($abooks as $abook) {
|
|
||||||
if(array_key_exists('abook_blocked',$abook) && intval($abook['abook_blocked'])) {
|
|
||||||
$abook['abook_flags'] |= ABOOK_FLAG_BLOCKED;
|
|
||||||
}
|
|
||||||
if(array_key_exists('abook_ignored',$abook) && intval($abook['abook_ignored'])) {
|
|
||||||
$abook['abook_flags'] |= ABOOK_FLAG_IGNORED;
|
|
||||||
}
|
|
||||||
if(array_key_exists('abook_hidden',$abook) && intval($abook['abook_hidden'])) {
|
|
||||||
$abook['abook_flags'] |= ABOOK_FLAG_HIDDEN;
|
|
||||||
}
|
|
||||||
if(array_key_exists('abook_archived',$abook) && intval($abook['abook_archived'])) {
|
|
||||||
$abook['abook_flags'] |= ABOOK_FLAG_ARCHIVED;
|
|
||||||
}
|
|
||||||
if(array_key_exists('abook_pending',$abook) && intval($abook['abook_pending'])) {
|
|
||||||
$abook['abook_flags'] |= ABOOK_FLAG_PENDING;
|
|
||||||
}
|
|
||||||
if(array_key_exists('abook_unconnected',$abook) && intval($abook['abook_unconnected'])) {
|
|
||||||
$abook['abook_flags'] |= ABOOK_FLAG_UNCONNECTED;
|
|
||||||
}
|
|
||||||
if(array_key_exists('abook_self',$abook) && intval($abook['abook_self'])) {
|
|
||||||
$abook['abook_flags'] |= ABOOK_FLAG_SELF;
|
|
||||||
}
|
|
||||||
if(array_key_exists('abook_feed',$abook) && intval($abook['abook_feed'])) {
|
|
||||||
$abook['abook_flags'] |= ABOOK_FLAG_FEED;
|
|
||||||
}
|
|
||||||
|
|
||||||
if(! ( $abook['abook_flags'] & ABOOK_FLAG_SELF)) {
|
|
||||||
if($max_friends !== false && $friends > $max_friends)
|
|
||||||
continue;
|
|
||||||
if($max_feeds !== false && ($abook['abook_flags'] & ABOOK_FLAG_FEED) && $feeds > $max_feeds)
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
unset($abook['abook_id']);
|
|
||||||
$abook['abook_account'] = get_account_id();
|
|
||||||
$abook['abook_channel'] = $channel['channel_id'];
|
|
||||||
dbesc_array($abook);
|
|
||||||
$r = dbq("INSERT INTO abook (`"
|
|
||||||
. implode("`, `", array_keys($abook))
|
|
||||||
. "`) VALUES ('"
|
|
||||||
. implode("', '", array_values($abook))
|
|
||||||
. "')" );
|
|
||||||
>>>>>>> d882b3274bd3b2479b924683b75b03c7854ad453
|
|
||||||
|
|
||||||
// import contacts
|
// import contacts
|
||||||
$abooks = $data['abook'];
|
$abooks = $data['abook'];
|
||||||
if($abooks) {
|
if($abooks) {
|
||||||
foreach($abooks as $abook) {
|
foreach($abooks as $abook) {
|
||||||
if($max_friends !== false && $friends > $max_friends)
|
|
||||||
continue;
|
|
||||||
if($max_feeds !== false && intval($abook['abook_feed']) && ($feeds > $max_feeds))
|
|
||||||
continue;
|
|
||||||
|
|
||||||
unset($abook['abook_id']);
|
unset($abook['abook_id']);
|
||||||
unset($abook['abook_rating']);
|
unset($abook['abook_rating']);
|
||||||
@ -526,6 +470,12 @@ function import_post(&$a) {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else {
|
||||||
|
if($max_friends !== false && $friends > $max_friends)
|
||||||
|
continue;
|
||||||
|
if($max_feeds !== false && intval($abook['abook_feed']) && ($feeds > $max_feeds))
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
dbesc_array($abook);
|
dbesc_array($abook);
|
||||||
$r = dbq("INSERT INTO abook (`"
|
$r = dbq("INSERT INTO abook (`"
|
||||||
|
Reference in New Issue
Block a user