Document model#update in tutorial

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Unresolved
    • Priority: Minor - P4
    • None
    • Affects Version/s: None
    • Component/s: Docs
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      There is an api doc for this method in lib/mongoid/persistable/updatable.rb:

            # Update the document attributes in the database.
            #
            # @example Update the document's attributes
            #   document.update(:title => "Sir")
            #
            # @param [ Hash ] attributes The attributes to update.
            #
            # @return [ true, false ] True if validation passed, false if not.
            #
            # @since 1.0.0
      

      This doesn't say whether a document will be updated if validation failed, and according to 4597 we do that on a has_many association.

            Assignee:
            Unassigned
            Reporter:
            Oleg Pudeyev (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: