mirror of
https://github.com/mastodon/mastodon.git
synced 2024-11-24 06:46:29 +00:00
249991c498
Conflicts: - Gemfile.lock - app/controllers/accounts_controller.rb - app/controllers/admin/dashboard_controller.rb - app/controllers/follower_accounts_controller.rb - app/controllers/following_accounts_controller.rb - app/controllers/remote_follow_controller.rb - app/controllers/stream_entries_controller.rb - app/controllers/tags_controller.rb - app/javascript/packs/public.js - app/lib/sanitize_config.rb - app/models/account.rb - app/models/form/admin_settings.rb - app/models/media_attachment.rb - app/models/stream_entry.rb - app/models/user.rb - app/serializers/initial_state_serializer.rb - app/services/batched_remove_status_service.rb - app/services/post_status_service.rb - app/services/process_mentions_service.rb - app/services/reblog_service.rb - app/services/remove_status_service.rb - app/views/admin/settings/edit.html.haml - config/locales/simple_form.pl.yml - config/settings.yml - docker-compose.yml
48 lines
849 B
Ruby
48 lines
849 B
Ruby
# frozen_string_literal: true
|
|
|
|
class AboutController < ApplicationController
|
|
before_action :set_pack
|
|
layout 'public'
|
|
|
|
before_action :set_body_classes, only: :show
|
|
before_action :set_instance_presenter
|
|
before_action :set_expires_in
|
|
|
|
skip_before_action :check_user_permissions, only: [:more, :terms]
|
|
|
|
def show; end
|
|
|
|
def more
|
|
flash.now[:notice] = I18n.t('about.instance_actor_flash') if params[:instance_actor]
|
|
end
|
|
|
|
def terms; end
|
|
|
|
private
|
|
|
|
def new_user
|
|
User.new.tap do |user|
|
|
user.build_account
|
|
user.build_invite_request
|
|
end
|
|
end
|
|
|
|
helper_method :new_user
|
|
|
|
def set_pack
|
|
use_pack 'common'
|
|
end
|
|
|
|
def set_instance_presenter
|
|
@instance_presenter = InstancePresenter.new
|
|
end
|
|
|
|
def set_body_classes
|
|
@hide_navbar = true
|
|
end
|
|
|
|
def set_expires_in
|
|
expires_in 0, public: true
|
|
end
|
|
end
|