Merge branch 'soru/fix-regressions' into 'main'

fix: Emote settings and discovery fallback

See merge request famedly/fluffychat!366
This commit is contained in:
Krille Fear 2021-02-02 13:08:24 +00:00
commit e38879d37f
2 changed files with 3 additions and 3 deletions

View File

@ -161,8 +161,8 @@ class FluffyRoutes {
return ViewData(
leftView: (_) => Settings(),
mainView: (_) => EmotesSettings(
room: (settings.arguments as Map)['room'],
stateKey: (settings.arguments as Map)['stateKey'],
room: ((settings.arguments ?? {}) as Map)['room'],
stateKey: ((settings.arguments ?? {}) as Map)['stateKey'],
),
);
case 'ignore':

View File

@ -110,7 +110,7 @@ class _DiscoverState extends State<Discover> {
}).then((PublicRoomsResponse res) {
if (widget.alias != null &&
!res.chunk.any((room) =>
room.aliases.contains(widget.alias) ||
(room.aliases?.contains(widget.alias) ?? false) ||
room.canonicalAlias == widget.alias)) {
// we have to tack on the original alias
res.chunk.add(PublicRoom.fromJson(<String, dynamic>{