* Serialize the given `message` object into a string.
( fs: PathManipulation, basePath: AbsoluteFsPath, message: ɵParsedMessage, )
| 51 | * Serialize the given `message` object into a string. |
| 52 | */ |
| 53 | function serializeMessage( |
| 54 | fs: PathManipulation, |
| 55 | basePath: AbsoluteFsPath, |
| 56 | message: ɵParsedMessage, |
| 57 | ): string { |
| 58 | if (message.location === undefined) { |
| 59 | return ` - "${message.text}"`; |
| 60 | } else { |
| 61 | const locationFile = fs.relative(basePath, message.location.file); |
| 62 | const locationPosition = serializeLocationPosition(message.location); |
| 63 | return ` - "${message.text}" : ${locationFile}:${locationPosition}`; |
| 64 | } |
| 65 | } |
no test coverage detected
searching dependent graphs…