mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
core: fix setup
This commit is contained in:
1 file changed
+1
-1
@@ -73,7 +73,7 @@ async function post(ctx: Context) {
|
|||||||
),
|
),
|
||||||
]);
|
]);
|
||||||
fs.ensureDirSync(path.resolve(os.homedir(), '.hydro'));
|
fs.ensureDirSync(path.resolve(os.homedir(), '.hydro'));
|
||||||
fs.writeFileSync(path.resolve(os.homedir(), '.hydro', 'config.json'), JSON.stringify({ url }));
|
fs.writeFileSync(path.resolve(os.homedir(), '.hydro', 'config.json'), JSON.stringify({ url: ctx.request.body.url }));
|
||||||
ctx.body = '<h1>Done! Hydro is now starting.</h1>';
|
ctx.body = '<h1>Done! Hydro is now starting.</h1>';
|
||||||
resolve?.();
|
resolve?.();
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|||||||
Reference in new issue
Block a user