| 500 | // TODO: Check if the link is reachable before appending it to the error |
| 501 | // message. |
| 502 | const generateDocumentationLink = func => { |
| 503 | const { funcName, funcClass } = extractFuncNameAndClass(func); |
| 504 | const p5BaseUrl = 'https://p5js.org/reference'; |
| 505 | const url = `${p5BaseUrl}/${funcClass}/${funcName}`; |
| 506 | |
| 507 | return url; |
| 508 | }; |
| 509 | |
| 510 | if (currentError.code === 'too_big' || currentError.code === 'too_small') { |
| 511 | const documentationLink = generateDocumentationLink(func); |
no test coverage detected