mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-22 21:42:50 +02:00
Fix permalink bug in uglyurls mode (refs #187).
This commit is contained in:
@@ -277,7 +277,8 @@ func (p *Page) permalink() (*url.URL, error) {
|
||||
|
||||
if len(pSlug) > 0 {
|
||||
if p.Site.Config != nil && p.Site.Config.UglyUrls {
|
||||
permalink = path.Join(dir, p.Slug, p.Extension)
|
||||
filename := fmt.Sprintf("%s.%s", p.Slug, p.Extension)
|
||||
permalink = path.Join(dir, filename)
|
||||
} else {
|
||||
permalink = path.Join(dir, p.Slug) + "/"
|
||||
}
|
||||
|
Reference in New Issue
Block a user