lib/eco/api/common/people/person_attribute_parser.rb in eco-helpers-2.0.25 vs lib/eco/api/common/people/person_attribute_parser.rb in eco-helpers-2.0.26
- old
+ new
@@ -4,9 +4,17 @@
module People
# Class to define a parser/serializer.
class PersonAttributeParser < Eco::Language::Models::ParserSerializer
+ # @note
+ # - This was introduced at a later stage and might not be available for certain org-parsers configs
+ # @return [RequiredAttrs]
+ def required_attrs
+ @required_attrs ||= @dependencies[:required_attrs]
+ #@required_attrs ||= RequiredAttrs.new(attr, :unkown, [attr])
+ end
+
# @see Eco::Language::Models::ParserSerializer#def_parser
# @note
# - additionally, you can declare a callback `active:` to determine if when the
# parser will be active/used.
# - this is important to help avoiding to set values that are not present in the input entry.