Permalink
Browse files

Merge branch 'master' of github.com:activescaffold/active_scaffold

  • Loading branch information...
2 parents f9523bd + 4aa4f21 commit dfdc9333e87a708a6ea01cee513bc3d5fb3f4ada scambra committed Mar 30, 2012
Showing with 4 additions and 4 deletions.
  1. +4 −4 lib/active_scaffold/actions/core.rb
@@ -112,16 +112,16 @@ def response_object
@response_object = successful? ? (@record || @records) : @record.errors
end
- # Success is the existence of certain variables and the absence of errors (when applicable).
- # Success can also be defined.
+ # Success is the existence of one or more model objects. Most actions
+ # circumvent this method by setting @success directly.
def successful?
if @successful.nil?
- @records or (@record and @record.errors.count == 0 and @record.no_errors_in_associated?)
+ @record || @records
else
@successful
end
end
-
+
def successful=(val)
@successful = (val) ? true : false
end

0 comments on commit dfdc933

Please sign in to comment.