Skip to content

Commit

Permalink
Rename translation key
Browse files Browse the repository at this point in the history
Rename `operation.error.oauth_access_token_notify_required` key to
`operation.error.oauth.access_token_notify_required`.

Missed this in the translation key changes in v0.19.
  • Loading branch information
akadusei committed Jun 17, 2023
1 parent 89336b5 commit 245f15e
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 4 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## [Unreleased] -

### Changed
- I18n: Rename `operation.error.oauth_access_token_notify_required` key to `operation.error.oauth.access_token_notify_required`

## [1.0.1] - 2023-06-02

### Fixed
Expand Down
1 change: 1 addition & 0 deletions docs/14-I18N.md
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,7 @@ en:
user_not_found: User does not exist

oauth:
access_token_notify_required: OAuth access token notification was not set
client_id_required: Client ID is required
client_inactive: Client is inactive
client_not_authorized: Client is not allowed to perform this action
Expand Down
2 changes: 1 addition & 1 deletion spec/shield/operations/mixins/save_user_settings_spec.cr
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ describe Shield::SaveUserSettings do
user.should be_nil

operation.oauth_access_token_notify.should have_error(
"operation.error.oauth_access_token_notify_required"
"operation.error.oauth.access_token_notify_required"
)
end
end
Expand Down
2 changes: 1 addition & 1 deletion spec/shield/operations/save_user_options_spec.cr
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ describe Shield::SaveUserOptions do
user_options.should be_nil

operation.oauth_access_token_notify
.should(have_error "operation.error.oauth_access_token_notify_required")
.should(have_error "operation.error.oauth.access_token_notify_required")
end
end
end
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ module Shield::SaveOauthClientUserOptions

private def validate_oauth_access_token_notify_required
validate_required oauth_access_token_notify,
message: Rex.t(:"operation.error.oauth_access_token_notify_required")
message: Rex.t(:"operation.error.oauth.access_token_notify_required")
end
end
end
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ module Shield::SaveOauthClientUserSettings
return unless new_record?

validate_required oauth_access_token_notify,
message: Rex.t(:"operation.error.oauth_access_token_notify_required")
message: Rex.t(:"operation.error.oauth.access_token_notify_required")
end

private def set_oauth_access_token_notify
Expand Down

0 comments on commit 245f15e

Please sign in to comment.