Skip to content

Commit

Permalink
[api] Fix download api (vercel#4512)
Browse files Browse the repository at this point in the history
The list examples api was updated in vercel#4511 but we also need to update the download example api.
  • Loading branch information
styfle authored May 27, 2020
1 parent cfb84b5 commit e844a38
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion api/examples/download/[segment].ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ export default withApiHandler(async function(req: NowRequest, res: NowResponse)
const example = segment.slice(0, -ext.length);

await extract('https://github.com/vercel/vercel/archive/master.zip', TMP_DIR);
const directory = `${TMP_DIR}/now-master/examples/${example}`;
const directory = `${TMP_DIR}/vercel-master/examples/${example}`;

if (!isDirectory(directory)) {
return notFound(res, `Example '${example}' was not found.`);
Expand Down

0 comments on commit e844a38

Please sign in to comment.