Fix attr2 join bug in loading scripts