From ca85658975dd6c85fbe5cc725698fe3a34d1234e Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Fri, 15 Jun 2018 18:00:23 +0200 Subject: Add autofollow option to invites (#7805) * Add autofollow option to invites * Trigger CodeClimate rebuild --- config/locales/en.yml | 1 + config/locales/simple_form.en.yml | 2 ++ 2 files changed, 3 insertions(+) (limited to 'config') diff --git a/config/locales/en.yml b/config/locales/en.yml index d128f92f3..46875d2ec 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -514,6 +514,7 @@ en: '86400': 1 day expires_in_prompt: Never generate: Generate + invited_by: 'You were invited by:' max_uses: one: 1 use other: "%{count} uses" diff --git a/config/locales/simple_form.en.yml b/config/locales/simple_form.en.yml index 85597e9a7..247a79218 100644 --- a/config/locales/simple_form.en.yml +++ b/config/locales/simple_form.en.yml @@ -3,6 +3,7 @@ en: simple_form: hints: defaults: + autofollow: People who sign up through the invite will automatically follow you avatar: PNG, GIF or JPG. At most 2MB. Will be downscaled to 400x400px bot: This account mainly performs automated actions and might not be monitored digest: Only sent after a long period of inactivity and only if you have received any personal messages in your absence @@ -30,6 +31,7 @@ en: name: Label value: Content defaults: + autofollow: Invite to follow your account avatar: Avatar bot: This is a bot account confirm_new_password: Confirm new password -- cgit From 53f0452b70445831664431ef7720d8ec2d361656 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Fri, 15 Jun 2018 19:46:25 +0200 Subject: Remove rack-timeout (#7809) Timeout considered harmful due to leaving the app in a broken state, including unreaped database connections --- Gemfile | 1 - Gemfile.lock | 2 -- config/initializers/timeout.rb | 6 ------ 3 files changed, 9 deletions(-) delete mode 100644 config/initializers/timeout.rb (limited to 'config') diff --git a/Gemfile b/Gemfile index cab4c4139..7a6e1568d 100644 --- a/Gemfile +++ b/Gemfile @@ -66,7 +66,6 @@ gem 'pundit', '~> 1.1' gem 'premailer-rails' gem 'rack-attack', '~> 5.2' gem 'rack-cors', '~> 1.0', require: 'rack/cors' -gem 'rack-timeout', '~> 0.4' gem 'rails-i18n', '~> 5.1' gem 'rails-settings-cached', '~> 0.6' gem 'redis', '~> 4.0', require: ['redis', 'redis/connection/hiredis'] diff --git a/Gemfile.lock b/Gemfile.lock index f7a377d45..fd4452f7d 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -425,7 +425,6 @@ GEM rack rack-test (1.0.0) rack (>= 1.0, < 3) - rack-timeout (0.4.2) rails (5.2.0) actioncable (= 5.2.0) actionmailer (= 5.2.0) @@ -726,7 +725,6 @@ DEPENDENCIES pundit (~> 1.1) rack-attack (~> 5.2) rack-cors (~> 1.0) - rack-timeout (~> 0.4) rails (~> 5.2.0) rails-controller-testing (~> 1.0) rails-i18n (~> 5.1) diff --git a/config/initializers/timeout.rb b/config/initializers/timeout.rb deleted file mode 100644 index de87fd906..000000000 --- a/config/initializers/timeout.rb +++ /dev/null @@ -1,6 +0,0 @@ -Rack::Timeout::Logger.disable -Rack::Timeout.service_timeout = false - -if Rails.env.production? - Rack::Timeout.service_timeout = 90 -end -- cgit From 0df91c7b1e05952ebbfc552915e995d55af0a403 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Fri, 15 Jun 2018 20:21:47 +0200 Subject: Add dat, dweb, ipfs, ipns, ssb, gopher protocols to URL extractor (#7810) * Add dat:// and gopher:// to URL extractor Fix #6072 * Fix comment indent * Add dweb, ipfs, ipns, ssb --- config/initializers/twitter_regex.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'config') diff --git a/config/initializers/twitter_regex.rb b/config/initializers/twitter_regex.rb index 7fa828300..c227f92d3 100644 --- a/config/initializers/twitter_regex.rb +++ b/config/initializers/twitter_regex.rb @@ -30,7 +30,7 @@ module Twitter ( # $1 total match (#{REGEXEN[:valid_url_preceding_chars]}) # $2 Preceeding chracter ( # $3 URL - (https?:\/\/)? # $4 Protocol (optional) + ((https?|dat|dweb|ipfs|ipns|ssb|gopher):\/\/)? # $4 Protocol (optional) (#{REGEXEN[:valid_domain]}) # $5 Domain(s) (?::(#{REGEXEN[:valid_port_number]}))? # $6 Port number (optional) (/#{REGEXEN[:valid_url_path]}*)? # $7 URL Path and anchor -- cgit