Add Date.prototype.toISOString()

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Done
    • Priority: Major - P3
    • None
    • Affects Version/s: 3.6.8
    • Component/s: Shell
    • None
    • ALL
    • Hide

      start mongo shell and try to execute following commands:

      u64vm(mongod-3.6.8) test> var d = Date()
      u64vm(mongod-3.6.8) test> d
      Thu Sep 27 2018 18:37:13 GMT+0300 (EEST)
      u64vm(mongod-3.6.8) test> d.toString()
      Thu Sep 27 2018 18:37:13 GMT+0300 (EEST)
      u64vm(mongod-3.6.8) test> d.toISOString()
      2018-09-27T18:37:29.057+0300 E QUERY [thread1] TypeError: d.toISOString is not a function :
      @(shell):1:1
      Show
      start mongo shell and try to execute following commands: u64vm(mongod-3.6.8) test> var d = Date() u64vm(mongod-3.6.8) test> d Thu Sep 27 2018 18:37:13 GMT+0300 (EEST) u64vm(mongod-3.6.8) test> d.toString() Thu Sep 27 2018 18:37:13 GMT+0300 (EEST) u64vm(mongod-3.6.8) test> d.toISOString() 2018-09-27T18:37:29.057+0300 E QUERY [thread1] TypeError: d.toISOString is not a function : @(shell):1:1
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None

      JavaScript in the mongo shell does not support toISOString() method on the Date object

            Assignee:
            Nick Brewer (Inactive)
            Reporter:
            Igor Solodovnikov
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: