forked from ppfun/pixelplanet
support otf fonts in captcha
This commit is contained in:
parent
057f60f049
commit
09c4b4c284
|
@ -20,7 +20,7 @@ if (isMainThread) {
|
|||
}
|
||||
|
||||
const font = fs.readdirSync(path.resolve(__dirname, '..', FONT_FOLDER))
|
||||
.filter((e) => e.endsWith('.ttf'))
|
||||
.filter((e) => e.endsWith('.ttf') || e.endsWith('.otf'))
|
||||
.map((e) => ppfunCaptcha.loadFont(
|
||||
path.resolve(__dirname, '..', FONT_FOLDER, e),
|
||||
));
|
||||
|
|
Loading…
Reference in New Issue
Block a user