modify GetScript method

by sort