mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-03-11 02:12:21 -05:00
Fix TypeError when updating slug
- added check slug before trim
This commit is contained in:
parent
b6507bed9b
commit
d812f99174
1 changed files with 1 additions and 1 deletions
|
@ -148,7 +148,7 @@ var PostSettingsMenuController = Ember.ObjectController.extend({
|
||||||
|
|
||||||
newSlug = newSlug || slug;
|
newSlug = newSlug || slug;
|
||||||
|
|
||||||
newSlug = newSlug.trim();
|
newSlug = newSlug && newSlug.trim();
|
||||||
|
|
||||||
// Ignore unchanged slugs or candidate slugs that are empty
|
// Ignore unchanged slugs or candidate slugs that are empty
|
||||||
if (!newSlug || slug === newSlug) {
|
if (!newSlug || slug === newSlug) {
|
||||||
|
|
Loading…
Add table
Reference in a new issue