(hostName string)
| 1204 | } |
| 1205 | |
| 1206 | func (p *PublicPost) CanonicalURL(hostName string) string { |
| 1207 | if p.Collection == nil || p.Collection.Alias == "" { |
| 1208 | return hostName + "/" + p.ID + ".md" |
| 1209 | } |
| 1210 | return p.Collection.CanonicalURL() + p.Slug.String |
| 1211 | } |
| 1212 | |
| 1213 | func (pp *PublicPost) DisplayCanonicalURL() string { |
| 1214 | us := pp.CanonicalURL(pp.Collection.hostName) |
no outgoing calls
no test coverage detected