Skip to content

Commit

Permalink
Short circuit client change detection for initial sync structure.
Browse files Browse the repository at this point in the history
  • Loading branch information
mrubinsk committed May 5, 2015
1 parent f1ec9f9 commit 60fd144
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions framework/ActiveSync/lib/Horde/ActiveSync/State/Base.php
Expand Up @@ -454,6 +454,15 @@ public function getChanges(array $options = array())

switch ($this->_collection['class']) {
case Horde_ActiveSync::CLASS_EMAIL:
// @todo Fix me with a changes object that transparently
// deals with different data structure for initial sync.
// ...or come up with better solution for dealing with
// memory usage.
if (!empty($changes) && !is_array($changes[0])) {
$this->_changes = $changes;
break;
}

$mailmap = $this->_getMailMapChanges($changes);
$flag_map = array(
Horde_ActiveSync::CHANGE_TYPE_FLAGS => 'flag change',
Expand Down

0 comments on commit 60fd144

Please sign in to comment.