make threading work, still doesn't extract right though