(tempFilePath: string, taskFilePathTemp: string)
| 62 | } |
| 63 | |
| 64 | function renameTemporaryFile(tempFilePath: string, taskFilePathTemp: string) { |
| 65 | return new Promise((resolve, reject) => { |
| 66 | fs.rename(tempFilePath, taskFilePathTemp, (err) => { |
| 67 | if (err) { |
| 68 | // this occurs in windows, don't know why. |
| 69 | return reject(err) // Reject the promise on error |
| 70 | } |
| 71 | resolve(null) |
| 72 | }) |
| 73 | }) |
| 74 | } |
| 75 | |
| 76 | export interface KeyCollectionResult { |
| 77 | allKeysMapping: any |