File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed
Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -324,16 +324,21 @@ void main() {
324324
325325 PerAccountStore prepare ({
326326 Map <String , String > realmEmoji = const {},
327+ bool addServerDataForPopular = true ,
327328 Map <String , List <String >>? unicodeEmoji,
328329 }) {
329330 final store = eg.store (
330331 initialSnapshot: eg.initialSnapshot (realmEmoji: {
331332 for (final MapEntry (: key, : value) in realmEmoji.entries)
332333 key: eg.realmEmojiItem (emojiCode: key, emojiName: value),
333334 }));
334- final extraEmojiData = ServerEmojiData (codeToNames: unicodeEmoji ?? {});
335- ServerEmojiData emojiData = eg.serverEmojiDataPopularPlus (extraEmojiData);
336- store.setServerEmojiData (emojiData);
335+ if (addServerDataForPopular || unicodeEmoji != null ) {
336+ final extraEmojiData = ServerEmojiData (codeToNames: unicodeEmoji ?? {});
337+ final emojiData = addServerDataForPopular
338+ ? eg.serverEmojiDataPopularPlus (extraEmojiData)
339+ : extraEmojiData;
340+ store.setServerEmojiData (emojiData);
341+ }
337342 return store;
338343 }
339344
You can’t perform that action at this time.
0 commit comments