Skip to content

armgit / zulip

Public Imported from GitHub
0

Zulip server and web application. Open-source team chat that helps teams stay productive and focused.

widget: Fix bug where 2nd line became poll question.

N-Shar-mab30eb4c4fcc5
diff --git a/zerver/lib/widget.py b/zerver/lib/widget.py
index e8abb156493..d3ae3ecabd8 100644
--- a/zerver/lib/widget.py
+++ b/zerver/lib/widget.py
@@ -14,7 +14,7 @@ def get_widget_data(content: str) -> Tuple[Optional[str], Optional[str]]:
if tokens[0].startswith("/"):
widget_type = tokens[0][1:]
if widget_type in valid_widget_types:
- remaining_content = content.replace(tokens[0], "", 1).strip()
+ remaining_content = content.replace(tokens[0], "", 1)
extra_data = get_extra_data_from_widget_type(remaining_content, widget_type)
return widget_type, extra_data