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

Invalid type for tagger option: Proc #21

Open
hwhelchel opened this issue Apr 27, 2017 · 0 comments
Open

Invalid type for tagger option: Proc #21

hwhelchel opened this issue Apr 27, 2017 · 0 comments

Comments

@hwhelchel
Copy link

@ngs thanks for making a great extension for middleman!

I'm trying to use the lambda tagger like so:

activate :similar, tagger: ->(resource) { [resource.data.category] }

But I'm getting an error:

/Users/harry/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/middleman-blog-similar-2.0.1/lib/middleman-blog-similar/extension.rb:31:in `after_configuration': Invalid type for tagger option: Proc (RuntimeError)
from /Users/harry/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/middleman-core-4.2.1/lib/middleman-core/extension.rb:405:in `block in bind_after_configuration'
from /Users/harry/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/middleman-core-4.2.1/lib/middleman-core/callback_manager.rb:57:in `instance_exec'
from /Users/harry/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/middleman-core-4.2.1/lib/middleman-core/callback_manager.rb:57:in `block in execute'
from /Users/harry/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/hamster-3.0.0/lib/hamster/vector.rb:1316:in `each'
from /Users/harry/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/hamster-3.0.0/lib/hamster/vector.rb:1316:in `traverse_depth_first'
from /Users/harry/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/hamster-3.0.0/lib/hamster/vector.rb:431:in `each'
from /Users/harry/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/middleman-core-4.2.1/lib/middleman-core/callback_manager.rb:57:in `execute'
from /Users/harry/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/contracts-0.13.0/lib/contracts/method_reference.rb:43:in `send_to'
from /Users/harry/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/contracts-0.13.0/lib/contracts/call_with.rb:76:in `call_with'
from /Users/harry/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/contracts-0.13.0/lib/contracts/method_handler.rb:138:in `block in redefine_method'
from /Users/harry/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/middleman-core-4.2.1/lib/middleman-core/callback_manager.rb:28:in `block in install_methods!'
from /Users/harry/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/middleman-core-4.2.1/lib/middleman-core/application.rb:306:in `initialize'
from /Users/harry/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/middleman-cli-4.2.1/bin/middleman:49:in `new'
from /Users/harry/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/middleman-cli-4.2.1/bin/middleman:49:in `<top (required)>'
from /Users/harry/.rbenv/versions/2.3.3/bin/middleman:22:in `load'
from /Users/harry/.rbenv/versions/2.3.3/bin/middleman:22:in `<main>'

Is this feature supported still?

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

No branches or pull requests

1 participant