Fixing Extract Script