Exemplo n.º 1
0
 public async Task <IActionResult> DeleteFile([FromQuery] string fileId, string directoryId, bool isPrivate = false)
 => await storageManager.DeleteFile(fileId)
      ? (directoryId == null ? (IActionResult)RedirectToAction(!isPrivate ? "Public" : "Private")
          : RedirectToAction("Directory", new { id = directoryId, isPrivate = isPrivate })).PushAlert("File has been deleted")
      : (directoryId == null ? (IActionResult)RedirectToAction(!isPrivate ? "Public" : "Private") : RedirectToAction("Directory", new { id = directoryId, isPrivate = isPrivate }));