fixed bug in upload avatar