Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: compatibility with null post.updated #117

Merged
merged 2 commits into from
Jul 29, 2020

Conversation

curbengh
Copy link
Contributor

@curbengh curbengh commented Nov 28, 2019

compatibility with hexojs/hexo#3887 hexojs/hexo#4278

@coveralls
Copy link

coveralls commented Nov 28, 2019

Coverage Status

Coverage remained the same at 100.0% when pulling e597747 on curbengh:optional-updated into 62f0cc2 on hexojs:master.

test/index.js Outdated
@@ -340,6 +341,25 @@ describe('Feed generator', () => {
feed_url: hexo.config.root + feedCfg.path
}));
});

it('no updated date', () => {
hexo.config.optional_updated = true;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Most probably this config won't be applied as processor doesn't run here.

test/index.js Outdated
@@ -45,7 +45,8 @@ describe('Feed generator', () => {
return Post.insert([
{source: 'foo', slug: 'foo', content: '<h6>TestHTML</h6>', date: 1e8},
{source: 'bar', slug: 'bar', date: 1e8 + 1},
{source: 'baz', slug: 'baz', title: 'With Image', image: 'test.png', date: 1e8 - 1}
{source: 'baz', slug: 'baz', title: 'With Image', image: 'test.png', date: 1e8 - 1},
{source: 'date', slug: 'date', title: 'date', date: 1e8 - 2, updated: undefined}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

will add a test case with valid updated.

@curbengh curbengh changed the title fix: compatibility with 'optional_updated' fix: compatibility with null post.updated Jun 22, 2020
@curbengh curbengh force-pushed the optional-updated branch 2 times, most recently from 404581a to 8fe15cd Compare June 25, 2020 07:02
package.json Outdated Show resolved Hide resolved
@curbengh curbengh marked this pull request as ready for review July 29, 2020 07:55
@curbengh curbengh merged commit 5819c7f into hexojs:master Jul 29, 2020
@curbengh curbengh deleted the optional-updated branch July 29, 2020 07:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants