File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed
web/src/app/api/releases/download/[version]/[filename] Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -17,8 +17,11 @@ export async function GET(
1717 return NextResponse . json ( { error : 'Missing parameters' } , { status : 400 } )
1818 }
1919
20+ // Freebuff releases use a "freebuff-v" tag prefix to avoid colliding with codebuff releases
21+ const tagPrefix = filename . startsWith ( 'freebuff-' ) ? 'freebuff-v' : 'v'
22+
2023 // Current download location - can be changed in the future without affecting old clients
21- const downloadUrl = `https://github.com/CodebuffAI/codebuff-community/releases/download/v ${ version } /${ filename } `
24+ const downloadUrl = `https://github.com/CodebuffAI/codebuff-community/releases/download/${ tagPrefix } ${ version } /${ filename } `
2225
2326 return NextResponse . redirect ( downloadUrl , 302 )
2427}
You can’t perform that action at this time.
0 commit comments