public synchronized static void deleteTask(String id, String mail) {

		try {

			XStream xstream = new XStream(new DomDriver());

			File remFile = new File((String) Server.prop.get("taskFilePath"));
			Task[] allTask = (Task[]) xstream.fromXML(remFile);

			List<Task> retList = new ArrayList<Task>(Arrays.asList(allTask));

			for (int i = 0; i < allTask.length; i++) {
				if (allTask[i].getId().equals(id) && allTask[i].getCreator().equals(mail) && allTask[i].getStatus().equals("in progress")) {
					retList.remove(i);
				}
			}

			FileOutputStream fos = new FileOutputStream(remFile);

			xstream.toXML(retList.toArray(new Task[0]), fos);
			fos.close();

		} catch (Exception e) {
		}
	}