mirror of
https://github.com/wukko/cobalt.git
synced 2025-05-29 21:10:14 +02:00
feat(setup): add cors option to setup script
This commit is contained in:
parent
450d01753d
commit
314c5fbfcc
@ -42,6 +42,12 @@ rl.question(q, r1 => {
|
|||||||
rl.question(q, r2 => {
|
rl.question(q, r2 => {
|
||||||
if (r2) ob['port'] = r2
|
if (r2) ob['port'] = r2
|
||||||
if (!r1 && r2) ob['selfURL'] = `http://localhost:${r2}/`
|
if (!r1 && r2) ob['selfURL'] = `http://localhost:${r2}/`
|
||||||
final()
|
|
||||||
|
console.log(Bright("\nIf you would like to enable CORS, enter 'y'. (y)\nCORS allows other websites and extensions to use your instance's API."))
|
||||||
|
|
||||||
|
rl.question(q, r3 => {
|
||||||
|
if (r3.toLowerCase() !== 'y') ob['cors'] = '0'
|
||||||
|
final()
|
||||||
|
})
|
||||||
});
|
});
|
||||||
})
|
})
|
||||||
|
Loading…
x
Reference in New Issue
Block a user