16 lines
288 B
Ruby
16 lines
288 B
Ruby
# frozen_string_literal: true
|
|
|
|
class NotePolicy < ApplicationPolicy
|
|
def revert?
|
|
update?
|
|
end
|
|
|
|
def permitted_attributes_for_create
|
|
[:x, :y, :width, :height, :body, :post_id, :html_id]
|
|
end
|
|
|
|
def permitted_attributes_for_update
|
|
[:x, :y, :width, :height, :body]
|
|
end
|
|
end
|