Skip to content

Commit

Permalink
fix: properly test http|https protocol
Browse files Browse the repository at this point in the history
  • Loading branch information
smeijer committed Dec 19, 2024
1 parent d3f221f commit 8d3d774
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scripts/liblab-gen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ async function writeJSON(path: string, data: any) {
}

async function readFile(path: string): Promise<string> {
if (/^http?s:\/\//.test(path)) {
if (/^https?:\/\//.test(path)) {
return fetch(path, { headers: { 'content-type': 'application/json' } }).then((x) => x.text());
}

Expand Down

0 comments on commit 8d3d774

Please sign in to comment.