* Implement function to prune string keeping HTML closing tags
Fixes#1587
* change const name
remove unneeded comment
* move pruneHTML to separated file
* move const back to telegram.go
* Add unit tests for string array manipulation and HTML pruning
Introduce comprehensive test cases for stringArr methods (Push, Pop, Unshift, Shift, String) to ensure correct behavior and state management. Additionally, add tests for HTML pruning functions (pruneHTML, pruneStringToWord) to validate handling of length constraints and formatting scenarios.
* Improve behavior
* Fix pruneHTML to count visible text only, add parent text pruning
- Fix bug where HTML tags were counted toward the character limit
instead of only visible text content
- Add pruning for parent comment text in Telegram notifications
- Simplify pruneStringToWord using strings.LastIndex
- Remove unused stringArr type and its tests
- Consolidate and simplify test cases
---------
Co-authored-by: Umputun <umputun@gmail.com>
Co-authored-by: Dmitry Verkhoturov <paskal.07@gmail.com>
Previously it was done through writing bot first,
clicking a button, copying the token, and pasting
it into the web interface.
The new flow is way simpler: click the link
to write bot a message, then click the "Check"
button in the web UI and you got notifications
enabled.
Due to the wrong order of `html.UnescapeString`
applying, messages sometimes ended up crippled.
Due to `parse_mode=Markdown` set in Telegram
send message call, `ParseMode` in message
was ignored.
* enable golangci-lint for momeory_store example
* add race_test option to makefile
* prune lost goroutine in TestRest_Shutdown
* run race tests without cache
* fix ci pipeline
* fix typos
* fresh vendor
* enforce vendor flag with env
* move tree to service package
* move controllers routing to rest.go, remove separate subrouters
* cleanup/formatting
* missing vendor packages
* move rss, img proxy, robots and getstarted to top-level routes
* simplify logger middleware usage
* randomize server test ports
* check for non-admin in admin tests
* lint: minor warns
* admin test to jwt admin