lib/wcc/contentful/simple_client/cdn.rb in wcc-contentful-1.3.2 vs lib/wcc/contentful/simple_client/cdn.rb in wcc-contentful-1.4.0.rc1

- old
+ new

@@ -79,16 +79,19 @@ # end # storage.put('sync_token', my_sync_token) def sync(sync_token: nil, **query, &block) return sync_old(sync_token: sync_token, **query) unless block_given? - sync_token = + query = { + # override default locale for sync queries + locale: nil + }.merge( if sync_token { sync_token: sync_token } else { initial: true } end - query = query.merge(sync_token) + ).merge(query) _instrument 'sync', sync_token: sync_token, query: query do resp = get('sync', query) resp = SyncResponse.new(resp) resp.assert_ok!