From aa5c621397df17c1d0e2cf1a455d8c7061bfdd56 Mon Sep 17 00:00:00 2001 From: Neil Alexander Date: Tue, 12 Jan 2021 12:45:29 +0000 Subject: [PATCH] Don't return error if there's no work to do --- syncapi/storage/shared/syncserver.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/syncapi/storage/shared/syncserver.go b/syncapi/storage/shared/syncserver.go index 4b615f40e..b2cd24fa1 100644 --- a/syncapi/storage/shared/syncserver.go +++ b/syncapi/storage/shared/syncserver.go @@ -909,7 +909,7 @@ func (d *Database) SendToDeviceUpdatesForSync( // If there's nothing to do then stop here. if len(events) == 0 { - return 0, nil, fmt.Errorf("no send-to-device messages for user %q device %q in range %d -> %d", userID, deviceID, from, to) + return 0, nil, nil } // If we've advanced past this stream position for this