module BeefCake
  module AttachedPermissionHelper
    def to_scope_s(attached_permission)
      return 'Full Access' if attached_permission.scope.empty?
      attached_permission
        .scope
        .map { |x| x.channel_payout.to_s.capitalize }
        .join(', ')
    end
  end
end
