Bug fix for extraction, and function loading