mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-03-11 02:12:21 -05:00
Merge pull request #2004 from ErisDS/issue-1992
Adding guard to meta_title
This commit is contained in:
commit
cccc19842e
1 changed files with 2 additions and 2 deletions
|
@ -385,14 +385,14 @@ coreHelpers.ghost_foot = function (options) {
|
|||
|
||||
coreHelpers.meta_title = function (options) {
|
||||
/*jslint unparam:true*/
|
||||
var title,
|
||||
var title = "",
|
||||
blog;
|
||||
|
||||
if (_.isString(this.relativeUrl)) {
|
||||
if (!this.relativeUrl || this.relativeUrl === '/' || this.relativeUrl === '' || this.relativeUrl.match(/\/page/)) {
|
||||
blog = config.theme();
|
||||
title = blog.title;
|
||||
} else {
|
||||
} else if (this.post) {
|
||||
title = this.post.title;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue