mirror of
https://github.com/nostrlabs-io/zap-stream-flutter.git
synced 2025-06-14 11:27:43 +00:00
fix: update default & current stream info
This commit is contained in:
@ -171,8 +171,20 @@ class _StreamConfigWidget extends State<StreamConfigWidget> {
|
||||
BasicButton.text(
|
||||
t.button.save,
|
||||
onTap: (context) async {
|
||||
final current = widget.currentStream?.getFirstTag("d");
|
||||
|
||||
// Update current first
|
||||
if (current != null) {
|
||||
await widget.api.updateDefaultStreamInfo(
|
||||
id: current,
|
||||
title: _title.text,
|
||||
summary: _summary.text,
|
||||
contentWarning: _nsfw ? "nsfw" : null,
|
||||
tags: _tags.text.split(","),
|
||||
);
|
||||
}
|
||||
// Updated default stream info (no id)
|
||||
await widget.api.updateDefaultStreamInfo(
|
||||
id: widget.currentStream?.getFirstTag("d"),
|
||||
title: _title.text,
|
||||
summary: _summary.text,
|
||||
contentWarning: _nsfw ? "nsfw" : null,
|
||||
|
Reference in New Issue
Block a user