corrected manifest code + threading fixes