cyrax 0.3.1 → 0.3.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +6 -14
- data/lib/cyrax/extensions/has_response.rb +1 -1
- data/lib/cyrax/extensions/has_service.rb +3 -3
- data/lib/cyrax/version.rb +1 -1
- metadata +13 -13
checksums.yaml
CHANGED
@@ -1,15 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
metadata.gz: !binary |-
|
9
|
-
YTMyMjg1NTNjOGJiYzIyZGVkMDUwYzMwNWMxZDA0NTRmOGRiYTljMWZmMWFk
|
10
|
-
YWQ1NjZmNmJlMmI0MDFlNzAxOGZhNDEwNTk5NDk3MmE4MjYyNzU3ZDc5ZGRh
|
11
|
-
YzY2Zjk1NDBlNjgzNjJkZjgzMDZkZTU5OThiZmZiM2QxMDM1NjI=
|
12
|
-
data.tar.gz: !binary |-
|
13
|
-
N2NjMWZlZWY2ZmIwMmZiZjBkZTljZjUzYzIzMDk5ZTBlODkzMDgxNTU0MjYz
|
14
|
-
Yzg3ZGNkMDc3ODdlZjUwOGRhZDVlNjk4NGJjOTI0YzAxMjkzNWE1YjQzZGFi
|
15
|
-
YmRlN2QwNDI2MDI2NmIxZTA1ODRjMWVjMGI1Nzk2ZjRmNjQ4Yzc=
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: c6cb52988ca75e1ff0e42e4ead186b615bf182ee
|
4
|
+
data.tar.gz: fb57424b1ace91f230b73e1b2ff421ab26666120
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 388e384b6b586fdbc4dfd55a8e9ae3380bad03b117a2242cce4828754bf63c3e3fa70a45f842900afda5f4efdaf869b25cd5ec7a5f71b1cdcc64797b10355b9f
|
7
|
+
data.tar.gz: cfc4d56f3c587efe4e25fda2616255c45b23ac84d67266a52f8ae4585fb2fb9311b7d9d5a33d2c12cabab3e16b8f4deaa255e08389c7003865ad3b257cb7d36c
|
@@ -9,7 +9,7 @@ module Cyrax::Extensions
|
|
9
9
|
|
10
10
|
def assign_resource(resource_name, resource, options = {})
|
11
11
|
if options[:decorator]
|
12
|
-
resource = Cyrax::
|
12
|
+
resource = Cyrax::Presenter.present(resource, options)
|
13
13
|
end
|
14
14
|
@_assignments ||= {}
|
15
15
|
@_assignments[resource_name.to_sym] = resource
|
@@ -22,7 +22,7 @@ module Cyrax::Extensions
|
|
22
22
|
invoke_callback(:after_create, resource)
|
23
23
|
invoke_callback(:after_save, resource)
|
24
24
|
set_message("#{resource_name.titleize} successfully created")
|
25
|
-
block.call if block_given?
|
25
|
+
block.call(resource) if block_given?
|
26
26
|
else
|
27
27
|
add_errors_from(resource)
|
28
28
|
end
|
@@ -48,7 +48,7 @@ module Cyrax::Extensions
|
|
48
48
|
invoke_callback(:after_update, resource)
|
49
49
|
invoke_callback(:after_save, resource)
|
50
50
|
set_message("#{resource_name.titleize} successfully updated")
|
51
|
-
block.call if block_given?
|
51
|
+
block.call(resource) if block_given?
|
52
52
|
else
|
53
53
|
add_errors_from(resource)
|
54
54
|
end
|
@@ -63,7 +63,7 @@ module Cyrax::Extensions
|
|
63
63
|
invoke_callback(:before_destroy, resource)
|
64
64
|
delete_resource(resource)
|
65
65
|
invoke_callback(:after_destroy, resource)
|
66
|
-
block.call if block_given?
|
66
|
+
block.call(resource) if block_given?
|
67
67
|
end
|
68
68
|
respond_with(resource)
|
69
69
|
end
|
data/lib/cyrax/version.rb
CHANGED
metadata
CHANGED
@@ -1,69 +1,69 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cyrax
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Droidlabs
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-
|
11
|
+
date: 2013-11-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- -
|
17
|
+
- - '>='
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: '0'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- -
|
24
|
+
- - '>='
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: activemodel
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- -
|
31
|
+
- - '>='
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: '0'
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- -
|
38
|
+
- - '>='
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: has_active_logger
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
|
-
- -
|
45
|
+
- - '>='
|
46
46
|
- !ruby/object:Gem::Version
|
47
47
|
version: '0'
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
|
-
- -
|
52
|
+
- - '>='
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '0'
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: rspec
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
|
-
- -
|
59
|
+
- - '>='
|
60
60
|
- !ruby/object:Gem::Version
|
61
61
|
version: '0'
|
62
62
|
type: :development
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
|
-
- -
|
66
|
+
- - '>='
|
67
67
|
- !ruby/object:Gem::Version
|
68
68
|
version: '0'
|
69
69
|
description: Small library for adding service layer to Rails projects
|
@@ -116,17 +116,17 @@ require_paths:
|
|
116
116
|
- lib
|
117
117
|
required_ruby_version: !ruby/object:Gem::Requirement
|
118
118
|
requirements:
|
119
|
-
- -
|
119
|
+
- - '>='
|
120
120
|
- !ruby/object:Gem::Version
|
121
121
|
version: '0'
|
122
122
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
123
123
|
requirements:
|
124
|
-
- -
|
124
|
+
- - '>='
|
125
125
|
- !ruby/object:Gem::Version
|
126
126
|
version: '0'
|
127
127
|
requirements: []
|
128
128
|
rubyforge_project:
|
129
|
-
rubygems_version: 2.0.
|
129
|
+
rubygems_version: 2.0.6
|
130
130
|
signing_key:
|
131
131
|
specification_version: 4
|
132
132
|
summary: Small library for adding service layer to Rails projects
|