merb-breadcrumbs 0.2.1 → 0.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.2.1
1
+ 0.2.3
@@ -17,7 +17,7 @@ module Merb
17
17
  def action_crumb
18
18
  crumb_function = self.class.action_crumbs[action_name.to_sym]
19
19
  case crumb_function
20
- when Symbol then push_crumb(self.send(crumb_function))
20
+ when Symbol then self.send(crumb_function)
21
21
  when String then push_crumb(crumb_function)
22
22
  when Array then push_crumb(*crumb_function)
23
23
  end
@@ -27,8 +27,14 @@ module Merb
27
27
 
28
28
  # Convenience method for laying a trail of breadcrumbs
29
29
  def breadcrumb_trail(*args)
30
+ options = if args.last.respond_to?(:each_pair)
31
+ args.pop
32
+ else
33
+ {}
34
+ end
35
+
30
36
  args.each do |arg|
31
- send(:before, "#{arg}_crumb".to_sym)
37
+ send(:before, "#{arg}_crumb".to_sym, options)
32
38
  end
33
39
  end
34
40
 
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{merb-breadcrumbs}
8
- s.version = "0.2.1"
8
+ s.version = "0.2.3"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Glen Mailer"]
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: merb-breadcrumbs
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Glen Mailer