diff options
| author | Sam Wilkins <samwilkins333@gmail.com> | 2019-09-18 04:31:53 -0400 |
|---|---|---|
| committer | Sam Wilkins <samwilkins333@gmail.com> | 2019-09-18 04:31:53 -0400 |
| commit | 30ec493a6dae644b0907f6ee6e86696c06aa11b4 (patch) | |
| tree | 52fa1d38f57386575fc888d6e804933497db468b /src/server/apis/google/GooglePhotosUploadUtils.ts | |
| parent | 960b5babede63780bf91ce8fe8658e8c41925ecb (diff) | |
additional timeunit
Diffstat (limited to 'src/server/apis/google/GooglePhotosUploadUtils.ts')
| -rw-r--r-- | src/server/apis/google/GooglePhotosUploadUtils.ts | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/server/apis/google/GooglePhotosUploadUtils.ts b/src/server/apis/google/GooglePhotosUploadUtils.ts index 9733c7ec5..9275bf125 100644 --- a/src/server/apis/google/GooglePhotosUploadUtils.ts +++ b/src/server/apis/google/GooglePhotosUploadUtils.ts @@ -80,7 +80,11 @@ export namespace GooglePhotosUploadUtils { }); })).newMediaItemResults; }; - const newMediaItemResults = await newMediaItems.batchedMapInterval({ batchSize: 50 }, createFromUploadTokens, 0.1); + const batcher = { batchSize: 50 }; + const interval = { magnitude: 100, unit: TimeUnit.Milliseconds }; + + const newMediaItemResults = await newMediaItems.batchedMapInterval(batcher, createFromUploadTokens, interval); + return { newMediaItemResults }; }; |
