From 2ff01f78f79d0b075e127a6aee05c4c429daf569 Mon Sep 17 00:00:00 2001 From: ThibG Date: Tue, 19 Jan 2021 06:47:36 +0100 Subject: Fix /activity endpoint not require signature in authorized fetch mode (#15592) Fixes #15589 Co-authored-by: Claire --- app/controllers/statuses_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'app') diff --git a/app/controllers/statuses_controller.rb b/app/controllers/statuses_controller.rb index 17ddd31fb..87612a296 100644 --- a/app/controllers/statuses_controller.rb +++ b/app/controllers/statuses_controller.rb @@ -8,7 +8,7 @@ class StatusesController < ApplicationController layout 'public' - before_action :require_signature!, only: :show, if: -> { request.format == :json && authorized_fetch_mode? } + before_action :require_signature!, only: [:show, :activity], if: -> { request.format == :json && authorized_fetch_mode? } before_action :set_status before_action :set_instance_presenter before_action :set_link_headers -- cgit From e955ca5463dc399694455bc25301d56499a1b6ef Mon Sep 17 00:00:00 2001 From: ThibG Date: Thu, 21 Jan 2021 06:18:30 +0100 Subject: Fix sign-up restrictions based on IP addresses not being enforced (#15607) Fixes #15606 Co-authored-by: Claire --- app/models/user.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'app') diff --git a/app/models/user.rb b/app/models/user.rb index f8c8a6ab5..b4508c2eb 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -152,7 +152,7 @@ class User < ApplicationRecord def confirm new_user = !confirmed? - self.approved = true if open_registrations? + self.approved = true if open_registrations? && !sign_up_from_ip_requires_approval? super -- cgit From 7d0031a515a9ccd552fab9ad55b6edb7e0e5ba32 Mon Sep 17 00:00:00 2001 From: ThibG Date: Thu, 21 Jan 2021 14:29:54 +0100 Subject: Fix Google Translate breaking web interface (#15610) - marks the page as a whole as untranslatable - still marks user text as translatable Co-authored-by: Claire --- app/javascript/mastodon/components/status_content.js | 8 ++++---- app/javascript/mastodon/features/account/components/header.js | 6 +++--- .../mastodon/features/getting_started/components/announcements.js | 2 +- app/views/home/index.html.haml | 2 +- app/views/public_timelines/show.html.haml | 2 +- app/views/tags/show.html.haml | 2 +- 6 files changed, 11 insertions(+), 11 deletions(-) (limited to 'app') diff --git a/app/javascript/mastodon/components/status_content.js b/app/javascript/mastodon/components/status_content.js index 185a2a663..190ced1a8 100644 --- a/app/javascript/mastodon/components/status_content.js +++ b/app/javascript/mastodon/components/status_content.js @@ -221,14 +221,14 @@ export default class StatusContent extends React.PureComponent { return (
{mentionsPlaceholder} -
+
{!hidden && !!status.get('poll') && } @@ -238,7 +238,7 @@ export default class StatusContent extends React.PureComponent { } else if (this.props.onClick) { const output = [
-
+
{!!status.get('poll') && } @@ -254,7 +254,7 @@ export default class StatusContent extends React.PureComponent { } else { return (
-
+
{!!status.get('poll') && } diff --git a/app/javascript/mastodon/features/account/components/header.js b/app/javascript/mastodon/features/account/components/header.js index b47ebed62..0b4431d62 100644 --- a/app/javascript/mastodon/features/account/components/header.js +++ b/app/javascript/mastodon/features/account/components/header.js @@ -328,9 +328,9 @@ class Header extends ImmutablePureComponent { ))} {fields.map((pair, i) => (
-
+
-
+
{pair.get('verified_at') && }
@@ -340,7 +340,7 @@ class Header extends ImmutablePureComponent { {account.get('id') !== me && !suspended && } - {account.get('note').length > 0 && account.get('note') !== '

' &&
} + {account.get('note').length > 0 && account.get('note') !== '

' &&
}
{!suspended && ( diff --git a/app/javascript/mastodon/features/getting_started/components/announcements.js b/app/javascript/mastodon/features/getting_started/components/announcements.js index 5bc3abac6..4534f7121 100644 --- a/app/javascript/mastodon/features/getting_started/components/announcements.js +++ b/app/javascript/mastodon/features/getting_started/components/announcements.js @@ -145,7 +145,7 @@ class Content extends ImmutablePureComponent { return (
diff --git a/app/views/home/index.html.haml b/app/views/home/index.html.haml index 94cc782b2..3d6283fba 100644 --- a/app/views/home/index.html.haml +++ b/app/views/home/index.html.haml @@ -8,7 +8,7 @@ = render_initial_state = javascript_pack_tag 'application', crossorigin: 'anonymous' -.app-holder#mastodon{ data: { props: Oj.dump(default_props) } } +.notranslate.app-holder#mastodon{ data: { props: Oj.dump(default_props) } } %noscript = image_pack_tag 'logo.svg', alt: 'Mastodon' diff --git a/app/views/public_timelines/show.html.haml b/app/views/public_timelines/show.html.haml index 3325be5bf..9254bd348 100644 --- a/app/views/public_timelines/show.html.haml +++ b/app/views/public_timelines/show.html.haml @@ -14,4 +14,4 @@ %p= t('about.browse_local_posts') #mastodon-timeline{ data: { props: Oj.dump(default_props.merge(local: !Setting.show_known_fediverse_at_about_page)) }} -#modal-container +.notranslate#modal-container diff --git a/app/views/tags/show.html.haml b/app/views/tags/show.html.haml index beeeb56f2..5cd513b32 100644 --- a/app/views/tags/show.html.haml +++ b/app/views/tags/show.html.haml @@ -13,4 +13,4 @@ %p= t('about.about_hashtag_html', hashtag: @tag.name) #mastodon-timeline{ data: { props: Oj.dump(default_props.merge(hashtag: @tag.name, local: @local)) }} -#modal-container +.notranslate#modal-container -- cgit