diff options
author | Claire <claire.github-309c@sitedethib.com> | 2021-02-03 18:57:38 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-03 18:57:38 +0100 |
commit | 4ed9576cd28abc033a094fed6babe9825014f1af (patch) | |
tree | d6d5e7b07e24248da5c237726dca874727c10b38 /config/initializers | |
parent | 7632255115a7f6e6f9f8047f0d0d1b90d7ee9315 (diff) | |
parent | e1fa06c459a28a575d0da540432c61b702e99cdd (diff) |
Merge pull request #1496 from ClearlyClaire/glitch-soc/merge-upstream
Merge upstream changes
Diffstat (limited to 'config/initializers')
-rw-r--r-- | config/initializers/fast_blank.rb | 2 | ||||
-rw-r--r-- | config/initializers/simple_form.rb | 4 | ||||
-rw-r--r-- | config/initializers/twitter_regex.rb | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/config/initializers/fast_blank.rb b/config/initializers/fast_blank.rb index 174ea7664..f0b7cac78 100644 --- a/config/initializers/fast_blank.rb +++ b/config/initializers/fast_blank.rb @@ -1,5 +1,5 @@ if String.method_defined?(:blank_as?) class String - alias_method :blank?, :blank_as? + alias blank? blank_as? end end diff --git a/config/initializers/simple_form.rb b/config/initializers/simple_form.rb index 3dc48ef08..3a2097d2f 100644 --- a/config/initializers/simple_form.rb +++ b/config/initializers/simple_form.rb @@ -1,7 +1,7 @@ # Use this setup block to configure all options available in SimpleForm. module AppendComponent - def append(wrapper_options = nil) + def append(_wrapper_options = nil) @append ||= begin options[:append].to_s.html_safe if options[:append].present? end @@ -9,7 +9,7 @@ module AppendComponent end module RecommendedComponent - def recommended(wrapper_options = nil) + def recommended(_wrapper_options = nil) return unless options[:recommended] options[:label_text] = ->(raw_label_text, _required_label_text, _label_present) { safe_join([raw_label_text, ' ', content_tag(:span, I18n.t('simple_form.recommended'), class: 'recommended')]) } nil diff --git a/config/initializers/twitter_regex.rb b/config/initializers/twitter_regex.rb index 7f99a0005..aca85dd43 100644 --- a/config/initializers/twitter_regex.rb +++ b/config/initializers/twitter_regex.rb @@ -75,7 +75,7 @@ module Twitter # XMPP or magnet URIs an empty array will be returned. # # If a block is given then it will be called for each XMPP URI. - def extract_extra_uris_with_indices(text, options = {}) # :yields: uri, start, end + def extract_extra_uris_with_indices(text, _options = {}) # :yields: uri, start, end return [] unless text && text.index(":") urls = [] |