logo

mastofe

My custom branche(s) on git.pleroma.social/pleroma/mastofe git clone https://hacktivis.me/git/mastofe.git

conversation.rb (391B)


  1. # frozen_string_literal: true
  2. # == Schema Information
  3. #
  4. # Table name: conversations
  5. #
  6. # id :integer not null, primary key
  7. # uri :string
  8. # created_at :datetime not null
  9. # updated_at :datetime not null
  10. #
  11. class Conversation < ApplicationRecord
  12. validates :uri, uniqueness: true, if: :uri?
  13. has_many :statuses
  14. def local?
  15. uri.nil?
  16. end
  17. end