Add `reading:autoplay:gifs` to /api/v1/preferences (#22706)
This commit is contained in:
parent
fdd1facba1
commit
0e7549b82d
|
@ -7,6 +7,7 @@ class REST::PreferencesSerializer < ActiveModel::Serializer
|
||||||
|
|
||||||
attribute :reading_default_sensitive_media, key: 'reading:expand:media'
|
attribute :reading_default_sensitive_media, key: 'reading:expand:media'
|
||||||
attribute :reading_default_sensitive_text, key: 'reading:expand:spoilers'
|
attribute :reading_default_sensitive_text, key: 'reading:expand:spoilers'
|
||||||
|
attribute :reading_autoplay_gifs, key: 'reading:autoplay:gifs'
|
||||||
|
|
||||||
def posting_default_privacy
|
def posting_default_privacy
|
||||||
object.user.setting_default_privacy
|
object.user.setting_default_privacy
|
||||||
|
@ -27,4 +28,8 @@ class REST::PreferencesSerializer < ActiveModel::Serializer
|
||||||
def reading_default_sensitive_text
|
def reading_default_sensitive_text
|
||||||
object.user.setting_expand_spoilers
|
object.user.setting_expand_spoilers
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def reading_autoplay_gifs
|
||||||
|
object.user.setting_auto_play_gif
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
Reference in New Issue