fix(xep): Fix handling StanzaErrors from the DiscoManager
This commit is contained in:
parent
a928c5c877
commit
b92e825bc1
@ -5,8 +5,8 @@ import 'package:moxxmpp/src/jid.dart';
|
||||
import 'package:moxxmpp/src/managers/base.dart';
|
||||
import 'package:moxxmpp/src/managers/namespaces.dart';
|
||||
import 'package:moxxmpp/src/namespaces.dart';
|
||||
import 'package:moxxmpp/src/stanza.dart';
|
||||
import 'package:moxxmpp/src/stringxml.dart';
|
||||
import 'package:moxxmpp/src/xeps/xep_0030/errors.dart';
|
||||
import 'package:moxxmpp/src/xeps/xep_0030/types.dart';
|
||||
import 'package:moxxmpp/src/xeps/xep_0030/xep_0030.dart';
|
||||
import 'package:moxxmpp/src/xeps/xep_0060/errors.dart';
|
||||
@ -226,7 +226,7 @@ class UserAvatarManager extends XmppManagerBase {
|
||||
jid,
|
||||
node: userAvatarDataXmlns,
|
||||
);
|
||||
if (response.isType<DiscoError>()) return Result(UnknownAvatarError());
|
||||
if (response.isType<StanzaError>()) return Result(UnknownAvatarError());
|
||||
|
||||
final items = response.get<List<DiscoItem>>();
|
||||
if (items.isEmpty) return Result(UnknownAvatarError());
|
||||
|
Loading…
Reference in New Issue
Block a user