worskspace exists fix

pull/1647/head
filip mertens 3 years ago
parent 25f607b66c
commit e70ce1306e
  1. 2
      libs/remix-ui/workspace/src/lib/actions/workspace.ts

@ -263,7 +263,7 @@ export const uploadFile = async (target, targetFolder: string, cb?: (err: Error,
} }
const name = `${targetFolder}/${file.name}` const name = `${targetFolder}/${file.name}`
if (await workspaceProvider.exists(name)) { if (!await workspaceProvider.exists(name)) {
loadFile(name) loadFile(name)
} else { } else {
dispatch(displayNotification('Confirm overwrite', `The file ${name} already exists! Would you like to overwrite it?`, 'OK', null, () => { dispatch(displayNotification('Confirm overwrite', `The file ${name} already exists! Would you like to overwrite it?`, 'OK', null, () => {

Loading…
Cancel
Save