Fixed removal of planned workouts

Rename failed due to wrong directory
This commit is contained in:
Alejandro Martinez
2016-03-26 11:32:31 -03:00
parent abe25b0f66
commit f4fac0b3c3

View File

@@ -308,7 +308,7 @@ RideCache::removeCurrentRide()
// delete the file by renaming it
QString strOldFileName = context->ride->fileName;
QFile file(directory.canonicalPath() + "/" + strOldFileName);
QFile file((context->ride->planned ? plannedDirectory : directory).canonicalPath() + "/" + strOldFileName);
// purposefully don't remove the old ext so the user wouldn't have to figure out what the old file type was
QString strNewName = strOldFileName + ".bak";