mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-02-24 23:48:13 -05:00
Fixed error causing missing sidebar after import
no issue - the `Role.lowerCaseName` CP could throw an error when `name` was missing which caused the sidebar rendering to be aborted - adds a guard to ensure we aren't calling string methods on `null` or `undefined`
This commit is contained in:
parent
3ad9fb16d4
commit
a19c718e6c
1 changed files with 1 additions and 1 deletions
|
@ -12,6 +12,6 @@ export default Model.extend({
|
|||
updatedBy: attr('number'),
|
||||
|
||||
lowerCaseName: computed('name', function () {
|
||||
return this.get('name').toLocaleLowerCase();
|
||||
return (this.name || '').toLocaleLowerCase();
|
||||
})
|
||||
});
|
||||
|
|
Loading…
Add table
Reference in a new issue