correcting order of params and cleaning code in 6tus app