made some structure chnages