tanga_namespaced_helpers 0.0.5 → 0.0.6

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.
@@ -1,3 +1,3 @@
1
1
  module TangaNamespacedHelpers
2
- VERSION = "0.0.5"
2
+ VERSION = "0.0.6"
3
3
  end
@@ -23,7 +23,7 @@ module TangaNamespacedHelpers
23
23
  end
24
24
 
25
25
  def self.use_controller!
26
- @view = @original_context
26
+ @view = @original_context if @original_context
27
27
  end
28
28
 
29
29
  # TODO Gotta be a better way to do this.
@@ -38,8 +38,11 @@ module TangaNamespacedHelpers
38
38
  # So, if there's a NoMethodError (i.e. access the session after ActionMailer
39
39
  # resets the context), we need to reset it to the original controller
40
40
  # for the request and try one more time.
41
- TangaNamespacedHelpers.use_controller!
42
- view.send *args, &block
41
+ if TangaNamespacedHelpers.use_controller!
42
+ view.send *args, &block
43
+ else
44
+ raise
45
+ end
43
46
  end
44
47
 
45
48
  module ControllerMethods
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tanga_namespaced_helpers
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.5
4
+ version: 0.0.6
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: