Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DEVX-4928] Undeprecate Granite::Action#perform #139

Merged
merged 1 commit into from
Oct 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
## Next

## v0.17.4

* Undeprecate the `Granite::Action#perform` method.

## v0.17.3

* Stopped preconditions from being executed twice on `#try_perform!`
Expand Down
3 changes: 0 additions & 3 deletions lib/granite/action/performing.rb
Original file line number Diff line number Diff line change
Expand Up @@ -36,14 +36,11 @@ def perform(*)
# database transaction. Returns the result of execute_perform! method execution
# or true if method execution returned false or nil
#
# @deprecated Use {#perform!} or {#try_perform!} instead
# @param context [Symbol] can be optionally provided to define which
# validations to test against (the context is defined on validations
# using `:on`)
# @return [Object] result of execute_perform! method execution or false in case of errors
def perform(context: nil, **options)
Granite.deprecator.warn('Granite::Action#perform is deprecated, use #perform! or #try_perform! instead')

transaction do
raise Rollback unless valid?(context)

Expand Down
2 changes: 1 addition & 1 deletion lib/granite/version.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module Granite
VERSION = '0.17.3'.freeze
VERSION = '0.17.4'.freeze
end
2 changes: 1 addition & 1 deletion spec/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
require 'rspec/matchers/fail_matchers'
require 'simplecov'
SimpleCov.start do
minimum_coverage 99.66
minimum_coverage 99.63
end

require 'granite'
Expand Down