()
| 32 | } |
| 33 | |
| 34 | toJSON() { |
| 35 | const json = { |
| 36 | size: this.size, |
| 37 | newFilename: this.newFilename, |
| 38 | length: this.length, |
| 39 | originalFilename: this.originalFilename, |
| 40 | mimetype: this.mimetype, |
| 41 | }; |
| 42 | if (this.hash && this.hash !== '') { |
| 43 | json.hash = this.hash; |
| 44 | } |
| 45 | return json; |
| 46 | } |
| 47 | |
| 48 | toString() { |
| 49 | return `VolatileFile: ${this.originalFilename}`; |
no outgoing calls
no test coverage detected