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

Event localizer improvement #723

Merged
merged 2 commits into from Mar 26, 2021

Conversation

the-spectator
Copy link
Contributor

Related to #721

Summary

This PR adds #to_s method to AASM::Core::Event so we can directly use Model.aasm.human_event_name(event_object).
Following is the relevant code with addition to #to_s enables us to pass event_object.

list << :"#{i18n_scope(klass)}.events.#{i18n_klass(ancestor)}.#{event}"

@codeclimate
Copy link

codeclimate bot commented Oct 26, 2020

Code Climate has analyzed commit 3748cc0 and detected 0 issues on this pull request.

View more on Code Climate.

@codecov-io
Copy link

codecov-io commented Oct 26, 2020

Codecov Report

Merging #723 into master will increase coverage by 0.00%.
The diff coverage is 100.00%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #723   +/-   ##
=======================================
  Coverage   95.33%   95.33%           
=======================================
  Files          35       35           
  Lines        1242     1244    +2     
=======================================
+ Hits         1184     1186    +2     
  Misses         58       58           
Impacted Files Coverage Δ
lib/aasm/core/event.rb 97.80% <100.00%> (+0.04%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ea04160...3748cc0. Read the comment docs.

@anilmaurya anilmaurya merged commit 252ade3 into aasm:master Mar 26, 2021
@anilmaurya
Copy link
Member

Thank you for contributing @the-spectator

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants