Skip to content
This repository has been archived by the owner on Mar 31, 2023. It is now read-only.

Commit

Permalink
fix: pager index
Browse files Browse the repository at this point in the history
  • Loading branch information
vinicioslc committed Nov 29, 2020
1 parent c6384a2 commit ede2713
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/app/features/clickup/clickup_controller.dart
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ class ClickupController extends GetxController {
PageController activePageView = PageController();

void closeTask() async {
final task = await _fetchedTasks[activePageView.page.toInt() - 1];
final task = await _fetchedTasks[activePageView.page.toInt()];
final updated = await clickupService.updateTaskStatus(task["id"], toStatus);
_fetchedTasks[activePageView.page.toInt()] = updated;
update();
Expand All @@ -171,7 +171,7 @@ class ClickupController extends GetxController {
}

void reopenTask() async {
final task = await _fetchedTasks[activePageView.page.toInt() - 1];
final task = await _fetchedTasks[activePageView.page];
final updated =
await clickupService.updateTaskStatus(task["id"], fromStatus);
_fetchedTasks[activePageView.page.toInt()] = updated;
Expand Down

0 comments on commit ede2713

Please sign in to comment.