diff --git a/include/config.js b/include/config.js
index f154fce..5ac6220 100644
--- a/include/config.js
+++ b/include/config.js
@@ -4,6 +4,7 @@ const path = require('path');
const util = require('util');
const crypto = require('crypto');
const logger = require('hexo-log')();
+const { Migrator } = require('hexo-component-inferno/lib/core/migrate');
module.exports = hexo => {
if (!process.argv.includes('--icarus-dont-check-config')) {
@@ -32,7 +33,8 @@ module.exports = hexo => {
let cfg = yaml.parse(cfgStr);
// Check config version
if (!process.argv.includes('--icarus-dont-upgrade-config')) {
- const migrator = new(require('hexo-component-inferno/lib/core/migrate'))(path.join(hexo.theme_dir, 'include/migration'));
+ const head = require(path.join(hexo.theme_dir, 'include/migration/head'));
+ const migrator = new Migrator(head);
// Upgrade config
if (migrator.isOudated(cfg.version)) {
logger.info(`Your configuration file is outdated (${cfg.version} < ${migrator.getLatestVersion()}). `
@@ -57,7 +59,7 @@ module.exports = hexo => {
const result = schema.validate(cfg);
if (result !== true) {
logger.warn('Configuration file failed one or more checks.');
- logger.warn('Icarus may still run, but you will encounter excepted results.');
+ logger.warn('Icarus may still run, but you will encounter unexcepted results.');
logger.warn('Here is some information for you to correct the configuration file.');
logger.warn(util.inspect(result));
}
diff --git a/include/schema/common/comment.json b/include/schema/common/comment.json
index 5a68c06..a5e8cbd 100644
--- a/include/schema/common/comment.json
+++ b/include/schema/common/comment.json
@@ -28,6 +28,9 @@
{
"$ref": "/comment/livere.json"
},
+ {
+ "$ref": "/comment/utterances.json"
+ },
{
"$ref": "/comment/valine.json"
}
diff --git a/include/schema/common/donates.json b/include/schema/common/donates.json
index 9ee9c2a..ff5ca05 100644
--- a/include/schema/common/donates.json
+++ b/include/schema/common/donates.json
@@ -1,9 +1,10 @@
{
"$schema": "http://json-schema.org/draft-07/schema#",
"$id": "/common/donates.json",
- "description": "Donate plugin configurations",
+ "description": "Donate plugin configurations\nhttps://blog.zhangruipeng.me/hexo-theme-icarus/categories/Plugins/Donation/",
"type": "array",
"items": {
+ "type": "object",
"oneOf": [
{
"$ref": "/donate/alipay.json"
diff --git a/layout/archive.jsx b/layout/archive.jsx
index 7516755..e03f463 100644
--- a/layout/archive.jsx
+++ b/layout/archive.jsx
@@ -1,7 +1,7 @@
const moment = require('moment');
const { Component, Fragment } = require('inferno');
const Paginator = require('hexo-component-inferno/lib/view/misc/paginator');
-const ArticleMedia = require('hexo-component-inferno/lib/view/common/article-media');
+const ArticleMedia = require('hexo-component-inferno/lib/view/common/article_media');
module.exports = class extends Component {
render() {
diff --git a/layout/categories.jsx b/layout/categories.jsx
index 2efa9cb..7c1ceb1 100644
--- a/layout/categories.jsx
+++ b/layout/categories.jsx
@@ -5,6 +5,6 @@ module.exports = class extends Component {
render() {
const { site, page, helper } = this.props;
- return