update comments, delete duplicate function
Fixed session expired after uploading