mirror of
https://github.com/Start9Labs/start-os.git
synced 2026-03-26 10:21:52 +00:00
handle wh file uploads
This commit is contained in:
@@ -131,17 +131,13 @@ export default class GatewaysComponent {
|
||||
handler: async (input: typeof spec._TYPE) => {
|
||||
const loader = this.loader.open('Saving').subscribe()
|
||||
|
||||
console.log('FILE', input.config.value.file)
|
||||
|
||||
console.log(
|
||||
'FILE STRINGIFIED',
|
||||
JSON.stringify(input.config.value.file),
|
||||
)
|
||||
|
||||
try {
|
||||
await this.api.addTunnel({
|
||||
name: input.name,
|
||||
config: '' as string, // @TODO alex/matt when types arrive
|
||||
config:
|
||||
input.config.selection === 'paste'
|
||||
? input.config.value.file
|
||||
: await (input.config.value.file as any as File).text(),
|
||||
public: input.type === 'public',
|
||||
})
|
||||
return true
|
||||
|
||||
Reference in New Issue
Block a user