You are here

deleteSite

deleteSite() deletes a site.

Example

var site = siteService.getSite("site-to-delete");

if(site){
    
    site.deleteSite();

    site = siteService.getSite("site-to-delete");

    if(!site){
        model.message = "Site not found!";
    }
    else{
        model.message = "Site found!";
    }
}