happy_path 0.0.6 → 0.0.7
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.
- checksums.yaml +8 -8
- data/lib/happy_path.rb +2 -1
- data/lib/happy_path/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
---
|
|
2
2
|
!binary "U0hBMQ==":
|
|
3
3
|
metadata.gz: !binary |-
|
|
4
|
-
|
|
4
|
+
ODU5MjRmMWI1NDI5YzdiMGYxYjMwOTE5M2RiODA5NDE1YTQzYTQ2Ng==
|
|
5
5
|
data.tar.gz: !binary |-
|
|
6
|
-
|
|
6
|
+
MGU5ZjM4MGU2MDU4ODJmZjBlZGEyMDhiYTJiYWVmMTM1M2Y1NjI4NA==
|
|
7
7
|
SHA512:
|
|
8
8
|
metadata.gz: !binary |-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
M2JmMTUwYzgxYzZhMzk4YmVhMmFhODJhOTkyOWZjNTFiZGVkOWE4OTJhZTQz
|
|
10
|
+
NDBhOGVmMTg4NTM1ZjhhYTg5ZmNhMzZkOTIwZjBkOTk0NDAxYTgxM2U1MGIx
|
|
11
|
+
NmUyNTkwMzMxMmNiNjY1OTZmYjQ4MTg1ZWIzNjUyYWQ2NGJhNzg=
|
|
12
12
|
data.tar.gz: !binary |-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
Y2M2NzQ0N2UzOThlZGFhNTczNzg3MTUwOTJkMTdkMTE3OGVjOGVjNjQ5MWMz
|
|
14
|
+
NTMwMzIwYWMzMmE5YTY1ZDk1MDk1MzA5YmY4ZTcyNjZhYmRlODg2ZGYwNjM4
|
|
15
|
+
ZjBjNTg1NDBhYTY2MTE3YTBlZThkMDZlNWE0ZDEwMjA0YzY0ZjM=
|
data/lib/happy_path.rb
CHANGED
|
@@ -3,7 +3,8 @@ module HappyPath
|
|
|
3
3
|
|
|
4
4
|
def setup_happy_path
|
|
5
5
|
rescue_from ActiveRecord::RecordNotFound do |e|
|
|
6
|
-
|
|
6
|
+
class_constant = controller_name.classify.constantize rescue nil
|
|
7
|
+
raise e unless class_constant && self.respond_to?(:happy_paths) && HappyPath::PATHS.include?(params[:id]) && !class_constant.count.zero?
|
|
7
8
|
self.happy_paths(e, class_constant)
|
|
8
9
|
end
|
|
9
10
|
end
|
data/lib/happy_path/version.rb
CHANGED