Closed marcgreenstock closed 7 years ago
Validations fail if parent is nil.
parent
the belongs_to association here is required unless the active_record.belongs_to_required_by_default is false or optional is set to true:
belongs_to
active_record.belongs_to_required_by_default
optional
belongs_to :parent, class_name: name, foreign_key: ltree_parent_fragment_column, optional: true
Sorry duplicate of https://github.com/cfabianski/ltree_hierarchy/pull/20 closing
Validations fail if
parent
is nil.the
belongs_to
association here is required unless theactive_record.belongs_to_required_by_default
is false oroptional
is set to true: