File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -24,11 +24,11 @@ exports.create = function (api) {
2424
2525 if ( err && err . name === 'NotFoundError' ) {
2626 return cb ( null , fallbackName + '...(missing)' )
27- } else if ( value . content . type === 'post' && typeof value . content . text === 'string' ) {
27+ } else if ( value && value . content . type === 'post' && typeof value . content . text === 'string' ) {
2828 if ( value . content . text . trim ( ) ) {
2929 return cb ( null , titleFromMarkdown ( value . content . text , 40 ) || fallbackName )
3030 }
31- } else if ( typeof value . content . text === 'string' ) {
31+ } else if ( value && typeof value . content . text === 'string' ) {
3232 return cb ( null , value . content . type + ': ' + titleFromMarkdown ( value . content . text , 30 ) )
3333 } else {
3434 return getAboutName ( id , cb )
You can’t perform that action at this time.
0 commit comments