if the last char of the directory is not '/' then it will be added
bug of on_import() fixed
can now support ramdom play