[fix] fix bugs
This commit is contained in:
parent
970c49bd06
commit
5633852267
|
@ -2,7 +2,7 @@
|
||||||
function layoutDiv() {
|
function layoutDiv() {
|
||||||
var el = ''
|
var el = ''
|
||||||
el += `<nav class="menu dis-select${where == 'main' ? ' mobile-hidden' : ''}">`
|
el += `<nav class="menu dis-select${where == 'main' ? ' mobile-hidden' : ''}">`
|
||||||
for (let item of theme.menubar.items) {
|
for (let item of (theme.menubar.items || [])) {
|
||||||
if (item == undefined || item.id == null || item.url == null) {
|
if (item == undefined || item.id == null || item.url == null) {
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
|
|
@ -21,6 +21,9 @@ function getWikiObject(ctx) {
|
||||||
const data = ctx.locals.get('data')
|
const data = ctx.locals.get('data')
|
||||||
var list = []
|
var list = []
|
||||||
for (let key of Object.keys(data)) {
|
for (let key of Object.keys(data)) {
|
||||||
|
if (key.endsWith('.DS_Store')) {
|
||||||
|
continue
|
||||||
|
}
|
||||||
if (key.includes('wiki/') && key.length > 5) {
|
if (key.includes('wiki/') && key.length > 5) {
|
||||||
let newKey = key.replace('wiki/', '')
|
let newKey = key.replace('wiki/', '')
|
||||||
let obj = data[key]
|
let obj = data[key]
|
||||||
|
|
Loading…
Reference in New Issue