File tree Expand file tree Collapse file tree 1 file changed +4
-9
lines changed
Expand file tree Collapse file tree 1 file changed +4
-9
lines changed Original file line number Diff line number Diff line change @@ -390,16 +390,11 @@ export class Drive implements Contents.IDrive {
390390 * @returns A promise which resolves when the file is deleted.
391391 */
392392 async delete ( localPath : string ) : Promise < void > {
393- if ( localPath !== '' ) {
394- const currentDrive = extractCurrentDrive ( localPath , this . _drivesList ) ;
393+ const currentDrive = extractCurrentDrive ( localPath , this . _drivesList ) ;
395394
396- await deleteObjects ( currentDrive . name , {
397- path : formatPath ( localPath )
398- } ) ;
399- } else {
400- // create new element at root would mean modifying a drive
401- console . warn ( 'Operation not supported.' ) ;
402- }
395+ await deleteObjects ( currentDrive . name , {
396+ path : formatPath ( localPath )
397+ } ) ;
403398
404399 this . _fileChanged . emit ( {
405400 type : 'delete' ,
You can’t perform that action at this time.
0 commit comments