diff options
| author | Jeff Carr <[email protected]> | 2024-01-10 17:03:13 -0600 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2024-01-10 17:03:13 -0600 |
| commit | b3fce8457ff73a31fe889eb7b1315fae2e016cc4 (patch) | |
| tree | 4239220e449cf5039b063df92e4439294fca2a71 /common.go | |
| parent | 330927ee8d5802755ef2bddfe2bd9e71318a0666 (diff) | |
start fixing GetText() and move to any
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'common.go')
| -rw-r--r-- | common.go | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -124,8 +124,11 @@ func (n *Node) AppendText(str string) { // should get the value of the node func (n *Node) GetText() string { + if n.value != nil { + return n.value.(string) + } if (n.S != n.Text) { - log.Warn("GetText() is screwed up. TODO: fix this dumb crap") + log.Warn("GetText() is screwed up. TODO: fix this dumb crap. n.S =", n.S, "and n.Text =", n.Text) } if (n.S != "") { return n.S |
