import { AzExtTreeItem , IActionContext , ITreeItemPickerContext } from 'vscode-azureextensionui' ; import { localize } from '../localize' ; import { deleteNode } from './deleteNode' ; export async function deleteFunction ( context , node ? ) { ( < ITreeItemPickerContext > context ) . noItemFoundErrorMessage = localize ( 'noFunctionsToDelete' , 'No matching functions found or your function app is read-only.' ) ; await deleteNode ( context , /Remote;ReadWrite;Function;/i , node ) ; }