diff --git a/src/tt.h b/src/tt.h index 6d56abf..b11dadb 100644 --- a/src/tt.h +++ b/src/tt.h @@ -3,7 +3,7 @@ #include -#define TT_VERSION 1.0.0 +#define TT_VERSION 1.0.1 // global variables: extern std::string user_name; diff --git a/src/ui.cpp b/src/ui.cpp index c8d6ca5..acddf69 100644 --- a/src/ui.cpp +++ b/src/ui.cpp @@ -521,14 +521,14 @@ void command_rt(std::string input, int wtime, ProjectList *proj_list){ std::cout << "Task " << proj_list->active_project->name << "/" << proj_name << " does not exist." << std::endl; return ; } - proj_list->active_project->active_task->add_time(-wtime); + proj_list->active_project->active_task->add_time(-1*wtime); std::cout << wtime << "s removed from task " << proj_list->active_project->name << "/" << proj_list->active_project->active_task->name << std::endl; command_save(proj_list); return; }else{ int id=proj_list->active_project->find_task_id_by_name(trim(underscore_to_space(proj_name))); if (id >= 0){ - proj_list->active_project->tasks[id].add_time(-wtime); + proj_list->active_project->tasks[id].add_time(-1*wtime); std::cout << wtime << "s removed from task " << proj_list->active_project->name << "/" << proj_list->active_project->tasks[id].name << std::endl; command_save(proj_list); return; @@ -545,7 +545,7 @@ void command_rt(std::string input, int wtime, ProjectList *proj_list){ } int id=proj->find_task_id_by_name(trim(underscore_to_space(task_name))); if(id >= 0){ - proj->tasks[id].add_time(wtime); + proj->tasks[id].add_time(-1*wtime); std::cout << wtime << "s removed from task " << proj->name << "/" << proj->tasks[id].name << std::endl; command_save(proj_list); }else{