mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-23 15:18:58 +01:00
some minor fixes to make funambol happy
This commit is contained in:
parent
2082498285
commit
955f766a19
@ -630,6 +630,15 @@ class Horde_SyncML_State {
|
||||
*/
|
||||
function getPreferedContentType($type)
|
||||
{
|
||||
# if ($type == 'contacts') {
|
||||
# return 'text/x-vcard';
|
||||
# } elseif ($type == 'notes') {
|
||||
# return 'text/x-vnote';
|
||||
# } elseif ($type == 'tasks') {
|
||||
# return 'text/x-vcalendar';
|
||||
# } elseif ($type == 'calendar') {
|
||||
# return 'text/x-vcalendar';
|
||||
# }
|
||||
switch($type) {
|
||||
case 'contacts':
|
||||
return 'text/x-vcard';
|
||||
|
@ -36,7 +36,7 @@ class Horde_SyncML_Sync_SlowSync extends Horde_SyncML_Sync_TwoWaySync {
|
||||
# $adds = &$state->getAddedItems($hordeType);
|
||||
#}
|
||||
|
||||
#Horde::logMessage("SyncML: ".count($adds). ' added items found for '.$hordeType , __FILE__, __LINE__, PEAR_LOG_DEBUG);
|
||||
Horde::logMessage("SyncML: ".count($adds). ' added items found for '.$hordeType , __FILE__, __LINE__, PEAR_LOG_DEBUG);
|
||||
$serverAnchorNext = $state->getServerAnchorNext($syncType);
|
||||
$counter = 0;
|
||||
|
||||
@ -79,8 +79,8 @@ class Horde_SyncML_Sync_SlowSync extends Horde_SyncML_Sync_TwoWaySync {
|
||||
$state->log('Server-Add');
|
||||
|
||||
// return if we have to much data
|
||||
if(++$counter >= MAX_ENTRIES)
|
||||
{
|
||||
#Horde::logMessage("SyncML: ".' checking hordetype '.$hordeType , __FILE__, __LINE__, PEAR_LOG_DEBUG);
|
||||
if(++$counter >= MAX_ENTRIES && $hordeType != 'sifcalendar' && $hordeType != 'sifcontacts' && $hordeType != 'siftasks') {
|
||||
$state->setSyncStatus(SERVER_SYNC_DATA_PENDING);
|
||||
return $currentCmdID;
|
||||
}
|
||||
@ -229,7 +229,7 @@ class Horde_SyncML_Sync_SlowSync extends Horde_SyncML_Sync_TwoWaySync {
|
||||
$syncType = $this->_targetLocURI;
|
||||
$hordeType = str_replace('./','',$syncType);
|
||||
|
||||
#Horde::logMessage("SyncML: reading added items from database for $hordeType", __FILE__, __LINE__, PEAR_LOG_DEBUG);
|
||||
Horde::logMessage("SyncML: reading added items from database for $hordeType", __FILE__, __LINE__, PEAR_LOG_DEBUG);
|
||||
$state->setAddedItems($hordeType, $registry->call($hordeType. '/list', array()));
|
||||
$adds = &$state->getAddedItems($hordeType);
|
||||
$this->_syncDataLoaded = TRUE;
|
||||
|
@ -103,7 +103,7 @@ class Horde_SyncML_Sync_TwoWaySync extends Horde_SyncML_Sync {
|
||||
$state->log('Server-Replace');
|
||||
|
||||
// return if we have to much data
|
||||
if(++$counter >= MAX_ENTRIES) {
|
||||
if(++$counter >= MAX_ENTRIES && $hordeType != 'sifcalender' && $hordeType != 'sifcontacts' &&$hordeType != 'siftasks') {
|
||||
$state->setSyncStatus(SERVER_SYNC_DATA_PENDING);
|
||||
return $currentCmdID;
|
||||
}
|
||||
@ -139,8 +139,7 @@ class Horde_SyncML_Sync_TwoWaySync extends Horde_SyncML_Sync {
|
||||
$state->removeUID($syncType, $locid);
|
||||
|
||||
// return if we have to much data
|
||||
if(++$counter >= MAX_ENTRIES)
|
||||
{
|
||||
if(++$counter >= MAX_ENTRIES && $hordeType != 'sifcalender' && $hordeType != 'sifcontacts' &&$hordeType != 'siftasks') {
|
||||
$state->setSyncStatus(SERVER_SYNC_DATA_PENDING);
|
||||
return $currentCmdID;
|
||||
}
|
||||
@ -201,7 +200,7 @@ class Horde_SyncML_Sync_TwoWaySync extends Horde_SyncML_Sync {
|
||||
$state->log('Server-Add');
|
||||
|
||||
// return if we have to much data
|
||||
if(++$counter >= MAX_ENTRIES) {
|
||||
if(++$counter >= MAX_ENTRIES && $hordeType != 'sifcalender' && $hordeType != 'sifcontacts' &&$hordeType != 'siftasks') {
|
||||
$state->setSyncStatus(SERVER_SYNC_DATA_PENDING);
|
||||
return $currentCmdID;
|
||||
}
|
||||
@ -223,13 +222,13 @@ class Horde_SyncML_Sync_TwoWaySync extends Horde_SyncML_Sync {
|
||||
$hordeType = str_replace('./','',$syncType);
|
||||
$refts = $state->getServerAnchorLast($syncType);
|
||||
|
||||
#Horde::logMessage("SyncML: reading changed items from database", __FILE__, __LINE__, PEAR_LOG_DEBUG);
|
||||
Horde::logMessage("SyncML: reading changed items from database for $hordeType", __FILE__, __LINE__, PEAR_LOG_DEBUG);
|
||||
$state->setChangedItems($hordeType, $registry->call($hordeType. '/listBy', array('action' => 'modify', 'timestamp' => $refts)));
|
||||
|
||||
#Horde::logMessage("SyncML: reading deleted items from database", __FILE__, __LINE__, PEAR_LOG_DEBUG);
|
||||
Horde::logMessage("SyncML: reading deleted items from database for $hordeType", __FILE__, __LINE__, PEAR_LOG_DEBUG);
|
||||
$state->setDeletedItems($hordeType, $registry->call($hordeType. '/listBy', array('action' => 'delete', 'timestamp' => $refts)));
|
||||
|
||||
#Horde::logMessage("SyncML: reading added items from database", __FILE__, __LINE__, PEAR_LOG_DEBUG);
|
||||
Horde::logMessage("SyncML: reading added items from database for $hordeType", __FILE__, __LINE__, PEAR_LOG_DEBUG);
|
||||
$state->setAddedItems($hordeType, $registry->call($hordeType. '/listBy', array('action' => 'add', 'timestamp' => $refts)));
|
||||
|
||||
$this->_syncDataLoaded = TRUE;
|
||||
|
Loading…
Reference in New Issue
Block a user