resource_controller_extensions 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/lib/resource_controller_extensions/json.rb +2 -2
- metadata +2 -2
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.2.
|
1
|
+
0.2.1
|
@@ -18,10 +18,10 @@ module ResourceControllerExtensions
|
|
18
18
|
edit.wants.json { render :json => object}
|
19
19
|
|
20
20
|
create.wants.json { render :json => object, :status => :created, :location => object_url }
|
21
|
-
create.failure.wants.json { render :json => {:errors => object.errors}, :status => :unprocessable_entity }
|
21
|
+
create.failure.wants.json { render :json => {:errors => object.errors.full_messages}, :status => :unprocessable_entity }
|
22
22
|
destroy.wants.json { head :ok }
|
23
23
|
update.wants.json { head :ok }
|
24
|
-
update.failure.wants.json { render :json => {:errors => object.errors}, :status => :unprocessable_entity }
|
24
|
+
update.failure.wants.json { render :json => {:errors => object.errors.full_messages}, :status => :unprocessable_entity }
|
25
25
|
end
|
26
26
|
end
|
27
27
|
end
|