mirror of
https://github.com/discourse/discourse.git
synced 2026-08-05 02:43:08 -05:00
…as we do when publishing a mesage bus update: https://github.com/discourse/discourse/blob/07c93918ecbc82cda6cd9a079f27cfed432bcb7e/app/models/user.rb#L871-L871
14 lines
273 B
Ruby
14 lines
273 B
Ruby
# frozen_string_literal: true
|
|
|
|
class UserStatusSerializer < ApplicationSerializer
|
|
attributes :description, :emoji, :ends_at, :message_bus_last_id
|
|
|
|
def ends_at
|
|
object.ends_at&.iso8601
|
|
end
|
|
|
|
def message_bus_last_id
|
|
MessageBus.last_id("/user-status")
|
|
end
|
|
end
|