lib/origen/componentable.rb in origen-0.60.7 vs lib/origen/componentable.rb in origen-0.60.8

- old
+ new

@@ -575,9 +575,10 @@ # @return [Hash(Symbol, <ComponentableItem>)] containing the name of the component deleted and its component. # @raise [Origen::Componentable::NameDoesNotExistsError] Raised if :to_copy name does not exists. def delete(to_delete) obj = delete!(to_delete) fail Origen::Componentable::NameDoesNotExistError, "#{_singleton_name} name :#{to_delete} does not exist" if obj.nil? + obj end alias_method :remove, :delete # Same as the :delete method but raises an error if :name doesn't exists.