Compare commits
2 Commits
2a3449d0f2
...
55d2ef9c25
Author | SHA1 | Date | |
---|---|---|---|
55d2ef9c25 | |||
f37cbd1616 |
@ -252,10 +252,11 @@ class StickersManager extends XmppManagerBase {
|
||||
);
|
||||
}
|
||||
|
||||
/// Publishes the StickerPack [pack] to the PubSub node of [jid].
|
||||
/// Publishes the StickerPack [pack] to the PubSub node of [jid]. If specified, then
|
||||
/// [accessModel] will be used as the PubSub node's access model.
|
||||
///
|
||||
/// On success, returns true. On failure, returns a PubSubError.
|
||||
Future<Result<PubSubError, bool>> publishStickerPack(JID jid, StickerPack pack) async {
|
||||
Future<Result<PubSubError, bool>> publishStickerPack(JID jid, StickerPack pack, { String? accessModel }) async {
|
||||
assert(pack.id != '', 'The sticker pack must have an id');
|
||||
final pm = getAttributes().getManagerById<PubSubManager>(pubsubManager)!;
|
||||
|
||||
@ -264,8 +265,9 @@ class StickersManager extends XmppManagerBase {
|
||||
stickersXmlns,
|
||||
pack.toXML(),
|
||||
id: pack.id,
|
||||
options: const PubSubPublishOptions(
|
||||
options: PubSubPublishOptions(
|
||||
maxItems: 'max',
|
||||
accessModel: accessModel,
|
||||
),
|
||||
);
|
||||
}
|
||||
|
@ -6,7 +6,6 @@ import 'package:moxxmpp/src/namespaces.dart';
|
||||
import 'package:moxxmpp/src/stanza.dart';
|
||||
|
||||
class ReplyData {
|
||||
|
||||
const ReplyData({
|
||||
required this.to,
|
||||
required this.id,
|
||||
|
Loading…
Reference in New Issue
Block a user