]> git.giacomolli.uk - onechat/blobdiff - memory.go
Call sendRichMessage of the Bot API
[onechat] / memory.go
index d7fff4ee1d6e6fef5a7c84919dd8605ee5fd6beb..a3665a1d64a57d91e9b4255178b09dba63e66c8c 100644 (file)
--- a/memory.go
+++ b/memory.go
@@ -543,13 +543,13 @@ func (m *Memory) View() string {
        return m.chat.Render()
 }
 
-// ViewWithout returns the chat view without the leaf lines of the messages in
-// skip.
-func (m *Memory) ViewWithout(skip map[int]bool) string {
+// ViewLines returns the lines of the chat view, each with its newline, without
+// the leaf lines of the messages in skip.
+func (m *Memory) ViewLines(skip map[int]bool) []string {
        m.mutex.Lock()
        defer m.mutex.Unlock()
 
-       return m.chat.RenderWithout(skip)
+       return m.chat.LinesWithout(skip)
 }
 
 // Len returns the number of messages in the log.