lib/federails/configuration.rb in federails-0.2.0 vs lib/federails/configuration.rb in federails-0.3.0
- old
+ new
@@ -23,53 +23,32 @@
# Whether to enable ".well-known" and "nodeinfo" endpoints
mattr_accessor :enable_discovery
@@enable_discovery = true
- # Site port
+ # Does the site allow open registrations? (only used for nodeinfo reporting)
+ mattr_accessor :open_registrations
+ @@open_registrations = false
+
+ # Application layout
mattr_accessor :app_layout
@@app_layout = nil
- # User class name
- # @deprecated Kept for upgrade compatibility only
- mattr_accessor :user_class
- @@user_class = '::User'
-
# Route path for the federation URLs (to "Federails::Server::*" controllers)
mattr_accessor :server_routes_path
@@server_routes_path = :federation
# Route path for the webapp URLs (to "Federails::Client::*" controllers)
mattr_accessor :client_routes_path
@@client_routes_path = :app
+ # Default controller to use as base for client controllers
+ mattr_accessor :base_client_controller
+ @@base_client_controller = 'ActionController::Base'
+
# Route method for remote-following requests
mattr_accessor :remote_follow_url_method
@@remote_follow_url_method = 'federails.new_client_following_url'
-
- # Method to use for links to user profiles
- # @deprecated Set profile_url_method option on acts_as_federails_actor instead
- mattr_accessor :user_profile_url_method
- @@user_profile_url_method = nil
-
- # Attribute in the user model to use as the user's name
- # @deprecated Set name_field option on acts_as_federails_actor instead
- #
- # It only have sense if you have a separate username attribute
- mattr_accessor :user_name_field
- @@user_name_field = nil
-
- # Attribute in the user model to use as the username for local actors
- # @deprecated Set username_field option on acts_as_federails_actor instead
- mattr_accessor :user_username_field
- @@user_username_field = :id
-
- ##
- # @return [String] Table used for user model
- # @deprecated Kept for upgrade compatibility only
- def self.user_table
- @@user_class&.constantize&.table_name
- end
def self.site_host=(value)
@@site_host = value
Federails::Engine.routes.default_url_options[:host] = value
end