patch tasks.cpp so it supports upload file via update method now