()
| 17 | } |
| 18 | |
| 19 | toString() { |
| 20 | if (this.node) { |
| 21 | return this.node.error(this.text, { |
| 22 | index: this.index, |
| 23 | plugin: this.plugin, |
| 24 | word: this.word |
| 25 | }).message |
| 26 | } |
| 27 | |
| 28 | if (this.plugin) { |
| 29 | return this.plugin + ': ' + this.text |
| 30 | } |
| 31 | |
| 32 | return this.text |
| 33 | } |
| 34 | } |
| 35 | |
| 36 | module.exports = Warning |