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

Don't require the `scope` key in front matter defaults #2659

Merged
merged 2 commits into from Aug 1, 2014

Conversation

Projects
None yet
3 participants
@alfredxing
Member

alfredxing commented Jul 31, 2014

Set defaults for scope in front matter defaults as per #2656 by adding some "or"s.

Don't require the `scope` key in front matter defaults
Set defaults for `scope` in front matter defaults as per #2656
@parkr

This comment has been minimized.

Show comment
Hide comment
@parkr

parkr Jul 31, 2014

Member

Does this cover all three bullet points in #2656 or are you separating them out into separate PR's? Seems like this just covers scope.

Member

parkr commented Jul 31, 2014

Does this cover all three bullet points in #2656 or are you separating them out into separate PR's? Seems like this just covers scope.

@alfredxing

This comment has been minimized.

Show comment
Hide comment
@alfredxing

alfredxing Jul 31, 2014

Member

This addresses all three (well, the second one was already addressed by default). Line 66 addresses the first one, line 115 the third, and 86 just makes sure valid? matches theses changes.

Member

alfredxing commented Jul 31, 2014

This addresses all three (well, the second one was already addressed by default). Line 66 addresses the first one, line 115 the third, and 86 just makes sure valid? matches theses changes.

@parkr

This comment has been minimized.

Show comment
Hide comment
@parkr

parkr Jul 31, 2014

Member

This needs tests.

Member

parkr commented Jul 31, 2014

This needs tests.

@alfredxing

This comment has been minimized.

Show comment
Hide comment
@alfredxing

alfredxing Aug 1, 2014

Member

Tests added!

Member

alfredxing commented Aug 1, 2014

Tests added!

@parkr

This comment has been minimized.

Show comment
Hide comment
@parkr

parkr Aug 1, 2014

Member

Great, thanks! :)

Member

parkr commented Aug 1, 2014

Great, thanks! :)

@parkr parkr merged commit bc3b828 into jekyll:master Aug 1, 2014

1 check passed

continuous-integration/travis-ci The Travis CI build passed
Details

parkr added a commit that referenced this pull request Aug 1, 2014

@@ -83,7 +83,7 @@ def applies_type?(scope, type)
#
# Returns true if the set is valid and can be used in this class
def valid?(set)
set.is_a?(Hash) && set['scope'].is_a?(Hash) && set['scope']['path'].is_a?(String) && set['values'].is_a?(Hash)
set.is_a?(Hash) && set['values'].is_a?(Hash)

This comment has been minimized.

@parkr

parkr Aug 12, 2014

Member

What happens to set['scope'] if it's not set? Do all those checks above for scope.key?('path') fail?

@parkr

parkr Aug 12, 2014

Member

What happens to set['scope'] if it's not set? Do all those checks above for scope.key?('path') fail?

@jekyll jekyll locked and limited conversation to collaborators Feb 27, 2017

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.