discourse/lib/validators
Sam Saffron 0a5a6dfded DEV: stop mutating inputs as a side effect
We had quite a few cases in core where inputs are being mutated as a side
effect of calling a method.

This handles all the cases where specs caught this.

Mutating inputs makes code harder to reason about. Eg:

```
frog = "frog"
jump(frog)
puts frog
"fly" # ?????
```

This commit is part of a followup commit that adds # frozen_string_literal
to all our specs.
2019-04-30 10:25:53 +10:00
..
allow_user_locale_enabled_validator.rb DEV: Enable Style/SingleLineMethods and Style/Semicolon in Rubocop (#6717) 2018-12-04 11:48:13 +08:00
allowed_ip_address_validator.rb
alternative_reply_by_email_addresses_validator.rb
category_search_priority_weights_validator.rb FEATURE: Allow categories to be prioritized/deprioritized in search. (#7209) 2019-03-25 10:59:55 +08:00
censored_words_validator.rb Make rubocop happy again. 2018-06-07 13:28:18 +08:00
color_list_validator.rb FEATURE: custom colors for default letter avatars (#7167) 2019-03-18 16:24:21 +01:00
email_setting_validator.rb
email_validator.rb
enable_invite_only_validator.rb FIX: Do not allow invite_only and enable_sso at the same time 2019-04-02 10:26:27 -04:00
enable_local_logins_via_email_validator.rb
enable_private_email_messages_validator.rb
enable_sso_validator.rb FIX: Do not allow invite_only and enable_sso at the same time 2019-04-02 10:26:27 -04:00
external_system_avatars_validator.rb FEATURE: Add support for Unicode usernames and group names 2019-04-23 13:00:27 +02:00
group_setting_validator.rb FEATURE: Add site contact group. (#7152) 2019-03-13 11:34:47 +01:00
integer_setting_validator.rb
ip_address_format_validator.rb
max_emojis_validator.rb fix the build 2018-10-22 15:09:25 +05:30
max_username_length_validator.rb Remove unecessary code. 2018-10-02 15:24:12 +08:00
min_username_length_validator.rb Remove unecessary code. 2018-10-02 15:24:12 +08:00
password_validator.rb
pop3_polling_enabled_setting_validator.rb Make rubocop happy again. 2018-06-07 13:28:18 +08:00
post_validator.rb FIX: use ordered_posts for last post check, not the posts relation 2019-01-18 13:18:40 +11:00
quality_title_validator.rb
regex_presence_validator.rb
regex_setting_validation.rb
regex_setting_validator.rb
reply_by_email_address_validator.rb DEV: stop mutating inputs as a side effect 2019-04-30 10:25:53 +10:00
reply_by_email_enabled_validator.rb
sso_overrides_email_validator.rb
string_setting_validator.rb
stripped_length_validator.rb
topic_title_length_validator.rb Make rubocop happy again. 2018-06-07 13:28:18 +08:00
unicode_username_validator.rb FEATURE: Add support for Unicode usernames and group names 2019-04-23 13:00:27 +02:00
unicode_username_whitelist_validator.rb FEATURE: Add support for Unicode usernames and group names 2019-04-23 13:00:27 +02:00
unique_among_validator.rb
upload_url_validator.rb FIX: store the topic links using the cooked upload url 2018-08-14 12:23:32 +02:00
upload_validator.rb FEATURE: Upload Site Settings. (#6573) 2018-11-14 15:03:02 +08:00
url_validator.rb FIX: store the topic links using the cooked upload url 2018-08-14 12:23:32 +02:00
user_full_name_validator.rb
username_setting_validator.rb