Home > git-documentdb > GitDocumentDB > getOldRevision
GitDocumentDB.getOldRevision() method#
Get an old revision of a document
Signature:Parameters#
| Parameter | Type | Description |
|---|---|---|
| _id | string | _id is a file path whose extension is omitted. |
| revision | number | Specify a number to go back to old revision. Default is 0. See GitDocumentDB.getHistory() for the array of revisions. |
| historyOptions | HistoryOptions | The array of revisions is filtered by HistoryOptions.filter. |
Promise<JsonDoc | undefined>
Remarks#
undefined if a specified document does not exist or it is deleted.
This is an alias of GitDocumentDB#rootCollection.getOldRevision()