usememos / telegram-integration

Memogram is an easy to use integration service for syncing messages and images from a Telegram bot into your Memos.
78 stars 20 forks source link

fix: "forwarded from" string formatting #21

Closed alpaim closed 5 months ago

alpaim commented 5 months ago

Recent changes made in this commit introduced a string formatting bug.

The modified string

content = fmt.Sprintf("%s\n---\nForwarded from %s", originName, content)

resulted in the following formatted string:

Du Rove's Channel
---
Forwarded from MEMO_CONTENT

I've fixed it by reverting the changes to the original state, as it was in my PR prior to the recent commit. I've also removed a colon according to the formatting changes were made.

The corrected string now is:

content = fmt.Sprintf("Forwarded from %s\n%s", originName, content)

An example of the formatted string is:

Forwarded from Du Rove's Channel
MEMO_CONTENT