Skip to content

Commit d2d5613

Browse files
committed
api: Make serverEmojiDataUrl required in initial snapshot
Fixes-partly: #1837
1 parent 886245f commit d2d5613

File tree

3 files changed

+4
-11
lines changed

3 files changed

+4
-11
lines changed

lib/api/model/initial_snapshot.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ class InitialSnapshot {
109109

110110
final int maxFileUploadSizeMib;
111111

112-
final Uri? serverEmojiDataUrl; // TODO(server-6)
112+
final Uri serverEmojiDataUrl;
113113

114114
final String? realmEmptyTopicDisplayName; // TODO(server-10)
115115

lib/api/model/initial_snapshot.g.dart

Lines changed: 2 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/model/store.dart

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1117,12 +1117,7 @@ class UpdateMachine {
11171117
final updateMachine = UpdateMachine.fromInitialSnapshot(
11181118
store: store, initialSnapshot: initialSnapshot);
11191119
updateMachine.poll();
1120-
if (initialSnapshot.serverEmojiDataUrl != null) {
1121-
// TODO(server-6): If the server is ancient, just skip trying to have
1122-
// a list of its emoji. (The old servers that don't provide
1123-
// serverEmojiDataUrl are already unsupported at time of writing.)
1124-
unawaited(updateMachine.fetchEmojiData(initialSnapshot.serverEmojiDataUrl!));
1125-
}
1120+
unawaited(updateMachine.fetchEmojiData(initialSnapshot.serverEmojiDataUrl));
11261121
store.presence.start();
11271122
return updateMachine;
11281123
}

0 commit comments

Comments
 (0)