1
0
mirror of https://github.com/uetchy/namae.git synced 2025-03-17 12:30:32 +09:00

fix: limit nta result

This commit is contained in:
uetchy 2019-09-01 01:31:16 +09:00
parent 88a0374594
commit ff33c0b2d7

View File

@ -72,7 +72,6 @@ export default async function handler(
modifiedSection: entry[3], modifiedSection: entry[3],
} }
}) })
console.log(header)
send(res, { send(res, {
meta: { meta: {
@ -82,11 +81,13 @@ export default async function handler(
pages: parseInt(header[3]), pages: parseInt(header[3]),
}, },
result: result:
result.map((entry) => ({ result
.map((entry) => ({
name: entry.name, name: entry.name,
phoneticName: entry.phoneticName, phoneticName: entry.phoneticName,
englishName: entry.englishName, englishName: entry.englishName,
})) || [], }))
.slice(10) || [],
}) })
} catch (err) { } catch (err) {
sendError(res, err) sendError(res, err)