PlainDisplayTitle dynamically generates a title from the Post's contents if it doesn't already have an explicit title.
()
| 222 | // PlainDisplayTitle dynamically generates a title from the Post's contents if it |
| 223 | // doesn't already have an explicit title. |
| 224 | func (p *Post) PlainDisplayTitle() string { |
| 225 | if t := stripmd.Strip(p.DisplayTitle()); t != "" { |
| 226 | return t |
| 227 | } |
| 228 | return p.ID |
| 229 | } |
| 230 | |
| 231 | // FormattedDisplayTitle dynamically generates a title from the Post's contents if it |
| 232 | // doesn't already have an explicit title. |
no test coverage detected