change script to match new structure and fabric script