```ruby
class UserSerializer < ApplicationSerializer
  include MarkdownHelper

  attributes :avatar_url, :bio, :hearts_received, :last_hearted_at, :last_online, :staff, :url, :full_url,
    :email,
    :username, :dismiss_showcase_banner_url, :showcase_banner_dismissed_at,
    :coin_callout_viewed_at

  def dismiss_showcase_banner_url
    dismiss_showcase_banner_path(object)
  end

  def avatar_url
    object.avatar.url(288).to_s
  end

  def include_email?
    scope.try(:staff?)
  end

  def full_url
    user_url(object)
  end

  def last_online
    object.last_request_at.iso8601 if object.last_request_at?
  end

  def staff
    object.staff?
  end

  def url
    user_path(object)
  end
end
```

Allow staff to see encrypted_password (for migrations only)
user
```ruby
class UserSerializer < ApplicationSerializer
  include MarkdownHelper

  attributes :avatar_url, :bio, :hearts_received, :last_hearted_at, :last_online, :staff, :url, :full_url,
    :email,
    :username, :dismiss_showcase_banner_url, :showcase_banner_dismissed_at,
    :coin_callout_viewed_at,
    :staff_encrypted_password

  def dismiss_showcase_banner_url
    dismiss_showcase_banner_path(object)
  end

  def avatar_url
    object.avatar.url(288).to_s
  end

  def staff_encrypted_password
    scope.try(:staff?) ? object.encrypted_password : nil
  end

  def include_email?
    scope.try(:staff?)
  end

  def full_url
    user_url(object)
  end

  def last_online
    object.last_request_at.iso8601 if object.last_request_at?
  end

  def staff
    object.staff?
  end

  def url
    user_path(object)
  end
end
```
assistant