Commit dcc1e7a6 authored by nanahira's avatar nanahira

fix puppeteer install

parent 6a8045f8
......@@ -23,7 +23,6 @@ import { Logger, Random, Session } from 'koishi';
import initSqlJs from 'sql.js';
import * as localeZh from './locales/zh';
import * as localeEn from './locales/en';
import PuppeteerPlugin from 'koishi-plugin-puppeteer';
export * from './config';
......@@ -45,9 +44,6 @@ export default class YGOCardPlugin
@InjectLogger()
private logger: Logger;
@Inject()
private puppeteer: PuppeteerPlugin;
private dbs: SQL.Database[] = [];
private querySQL(db: SQL.Database, sql: string, params: any = {}) {
const statement = db.prepare(sql);
......@@ -134,7 +130,7 @@ export default class YGOCardPlugin
}
async renderCard(card: YGOProCard) {
if (!this.config.usePuppeteer || !this.puppeteer) {
if (!this.config.usePuppeteer || !this.ctx.puppeteer) {
return card.getDisplayString(this.config);
}
const img = card.getPic(this.config);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment