Overhauled AsyncTask system and fixed related bugs