@Override
	public synchronized void deleteFolder(String folderPath) throws IOException {

		checkDisposed();

		if (readOnly) {
			throw new ReadOnlyException();
		}

		if (SEPARATOR.equals(folderPath)) {
			throw new IOException("Root folder may not be deleted");
		}

		indexJournal.open();
		try {
			Folder folder = getFolder(folderPath, GetFolderOption.READ_ONLY);
			if (folder.folders.size() != 0 || folder.items.size() != 0) {
				throw new FolderNotEmptyException(folderPath + " is not empty");
			}

			indexJournal.deleteFolder(folderPath);

			folder.parent.folders.remove(folder.name);
		}
		catch (NotFoundException e) {
			return; // silent - folder already deleted
		}
		finally {
			indexJournal.close();
		}

		eventManager.folderDeleted(getParentPath(folderPath), getName(folderPath));
	}
Deallocate item storage
@param folderPath
@param itemName
Ghidra/Framework/FileSystem/src/main/java/ghidra/framework/store/local/IndexedLocalFileSystem.java