Browse Source

fix toot character advertisement

master
ida schmidt 2 weeks ago
parent
commit
277104aa05
1 changed files with 5 additions and 1 deletions
  1. 5
    1
      app/serializers/rest/instance_serializer.rb

+ 5
- 1
app/serializers/rest/instance_serializer.rb View File

@@ -5,7 +5,7 @@ class REST::InstanceSerializer < ActiveModel::Serializer
5 5
 
6 6
   attributes :uri, :title, :short_description, :description, :email,
7 7
              :version, :urls, :stats, :thumbnail,
8
-             :languages, :registrations, :approval_required
8
+             :languages, :registrations, :approval_required, :max_toot_chars
9 9
 
10 10
   has_one :contact_account, serializer: REST::AccountSerializer
11 11
 
@@ -59,6 +59,10 @@ class REST::InstanceSerializer < ActiveModel::Serializer
59 59
     Setting.registrations_mode != 'none' && !Rails.configuration.x.single_user_mode
60 60
   end
61 61
 
62
+  def max_toot_chars
63
+    69420
64
+  end
65
+
62 66
   def approval_required
63 67
     Setting.registrations_mode == 'approved'
64 68
   end

Loading…
Cancel
Save