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

Let #breadcrumbs_trail always find closest parent #1279

Merged
merged 1 commit into from
Dec 22, 2017
Merged

Conversation

denisdefreyne
Copy link
Member

@denisdefreyne denisdefreyne commented Dec 21, 2017

Fixes #1278.

#breadcrumbs_trail already supported cases like these:

/index.md
/foo.md.erb
/foo/stuff.html

# trail = [/index.md, /foo.md.erb, /foo/stuff.html]

but now it will also support

/index.md
/1.2.erb
/1.2/stuff.html

# trail = [/index.md, /1.2.erb, /1.2/stuff.html]
@iay
Copy link
Contributor

iay commented Dec 21, 2017

The fancy functional programming stuff is beyond my 2006-vintage understanding of Ruby but the intent seems right. I will try and do a quick test of this tomorrow and let you know whether it works for my case.

@iay
Copy link
Contributor

iay commented Dec 22, 2017

Dropping the modified breadcrumbs.rb into my lib/ directory seems to fix my particular use case.

@denisdefreyne denisdefreyne merged commit fe0d74a into master Dec 22, 2017
@denisdefreyne denisdefreyne deleted the gh-1278 branch December 22, 2017 16:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
2 participants