summaryrefslogtreecommitdiff
path: root/app/models/node.rb
diff options
context:
space:
mode:
authorerdgeist <erdgeist@erdgeist.org>2026-07-31 14:35:16 +0200
committererdgeist <erdgeist@erdgeist.org>2026-07-31 14:35:16 +0200
commit5f17f421b176d48ef556fb379f59bbb7d284b48e (patch)
tree15f07f480b07c385c88d43f827fc452b5b9df21a /app/models/node.rb
parenta90a77cfb913c7c0444ec793b47fd4be6fb66c9f (diff)
Retire the unused per-node permission subsystem
Every path through Permission raised or lied: validates_presence_of on a boolean made granted = false unsaveable, since false.blank? is true; get_permission_for read a nonexistent identifier attribute; has_permission? called an undefined plural method and returned a truthy relation in every case; and set_permission mutated granted without saving. Nothing outside the model referenced it and the table was empty.
Diffstat (limited to 'app/models/node.rb')
-rw-r--r--app/models/node.rb1
1 files changed, 0 insertions, 1 deletions
diff --git a/app/models/node.rb b/app/models/node.rb
index c8f9a210..1823daa4 100644
--- a/app/models/node.rb
+++ b/app/models/node.rb
@@ -18,7 +18,6 @@ class Node < ApplicationRecord
18 # them -- this dependent: :destroy is their only cleanup on node destroy. 18 # them -- this dependent: :destroy is their only cleanup on node destroy.
19 belongs_to :autosave, :class_name => "Page", :foreign_key => :autosave_id, :dependent => :destroy, optional: true 19 belongs_to :autosave, :class_name => "Page", :foreign_key => :autosave_id, :dependent => :destroy, optional: true
20 20
21 has_many :permissions, :dependent => :destroy
22 has_many :events, :dependent => :destroy 21 has_many :events, :dependent => :destroy
23 belongs_to :lock_owner, :class_name => "User", :foreign_key => :locking_user_id, optional: true 22 belongs_to :lock_owner, :class_name => "User", :foreign_key => :locking_user_id, optional: true
24 23