fixed initial upload bug