~whereswaldon/arbor-dev

Fix what I can from the suggestions. v1 SUPERSEDED

Daniel Wilkins: 1
 Fix what I can from the suggestions.

 1 files changed, 9 insertions(+), 13 deletions(-)
Export patchset (mbox)
How do I use this?

Copy & paste the following snippet into your terminal to import this patchset into git:

curl -s https://lists.sr.ht/~whereswaldon/arbor-dev/patches/14004/mbox | git am -3
Learn more about email & git

[PATCH] Fix what I can from the suggestions. Export this patch

---
 reply-view.go | 22 +++++++++-------------
 1 file changed, 9 insertions(+), 13 deletions(-)

diff --git a/reply-view.go b/reply-view.go
index 620fed0..ea845fa 100644
--- a/reply-view.go
+++ b/reply-view.go
@@ -310,7 +310,7 @@ func gatherParagraphs(text string) []string {

	for _, paragraph := range strings.Split(text, "\n") {
		// Remember to chomp blank lines at the start of the message
		if paragraph == "" && len(retVal) > 0 {
		if paragraph == "" && len(paragraphs) > 0 {
			stringIndex += 1
		} else {
			if len(paragraphs) <= stringIndex {
@@ -363,19 +363,15 @@ func (c *ReplyListView) sendReply() {
			}
		}
	} else {
		if err != nil {
			log.Printf("failed building reply: %v", err)
		} else {
			parent := c.ReplyingTo.Reply
		parent := c.ReplyingTo.Reply

			for _, text := range gatherParagraphs(replyText) {
				convo, err := nodeBuilder.NewReply(parent, text, []byte{})
				if err != nil {
					log.Printf("failed creating new conversation: %v", err)
				} else {
					c.postReply(author, convo)
					parent = convo
				}
		for _, text := range gatherParagraphs(replyText) {
			convo, err := nodeBuilder.NewReply(parent, text, []byte{})
			if err != nil {
				log.Printf("failed building reply: %v", err)
			} else {
				c.postReply(author, convo)
				parent = convo
			}
		}
	}
--
2.20.1