Skip to content

Commit

Permalink
Added the _total_count field so the client knows if there are more it…
Browse files Browse the repository at this point in the history
…ems to sync in the section
  • Loading branch information
bvisonl committed Jul 24, 2018
1 parent f639ce1 commit b6d53be
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions Entity/SyncState.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
class SyncState
{
const REAL_LAST_TIMESTAMP = "_real_last_timestamp";
const TOTAL_COUNT = "_total_count";
/**
* @var int
*
Expand Down
1 change: 1 addition & 0 deletions Service/SyncService.php
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ public function getFromMappings($mappings) {
'newItems' => json_decode($this->container->get('jms_serializer')->serialize($newItems, 'json'), true),
'failedItems' => json_decode($this->container->get('jms_serializer')->serialize($failedItems, 'json'), true),
SyncState::REAL_LAST_TIMESTAMP => $result[SyncState::REAL_LAST_TIMESTAMP],
SyncState::TOTAL_COUNT => $result[SyncState::TOTAL_COUNT],
);
}

Expand Down

0 comments on commit b6d53be

Please sign in to comment.