mirror of
https://github.com/FranP-code/public-apis.git
synced 2025-10-13 00:03:04 +00:00
Update conditional to use raw index of substring
This commit is contained in:
@@ -36,7 +36,7 @@ function setupMd(filename, anchor) {
|
|||||||
if (line.length < 2 || cur_line == lines.length) {
|
if (line.length < 2 || cur_line == lines.length) {
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
if (line.startsWith("|")) {
|
if (line.indexOf("|") == 0) {
|
||||||
arr.push(line + table_name)
|
arr.push(line + table_name)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -60,4 +60,4 @@ if (process.argv.length < 4) {
|
|||||||
} else {
|
} else {
|
||||||
anchorText = process.argv[3];
|
anchorText = process.argv[3];
|
||||||
}
|
}
|
||||||
setupMd(process.argv[2].toString(), anchorText);
|
setupMd(process.argv[2].toString(), anchorText);
|
||||||
|
|||||||
Reference in New Issue
Block a user