Class: Insika::Safety::Moderator::Verdict

Inherits:
Struct
  • Object
show all
Defined in:
lib/insika/safety/moderator.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#actionObject

Returns the value of attribute action

Returns:

  • (Object)

    the current value of action



22
23
24
# File 'lib/insika/safety/moderator.rb', line 22

def action
  @action
end

#categoryObject

Returns the value of attribute category

Returns:

  • (Object)

    the current value of category



22
23
24
# File 'lib/insika/safety/moderator.rb', line 22

def category
  @category
end

#reasonObject

Returns the value of attribute reason

Returns:

  • (Object)

    the current value of reason



22
23
24
# File 'lib/insika/safety/moderator.rb', line 22

def reason
  @reason
end

Instance Method Details

#block?Boolean

Returns:

  • (Boolean)


23
# File 'lib/insika/safety/moderator.rb', line 23

def block? = %w[refuse escalate].include?(action.to_s)

#unavailable?Boolean

Returns:

  • (Boolean)


24
# File 'lib/insika/safety/moderator.rb', line 24

def unavailable? = action.to_s == "unavailable"