revise the listFile function

use os.listdir to replace call function