Skip to content

Commit 891a4ad

Browse files
authored
Fixed TaskRepository.getList so it returns a list instead of a single task
1 parent dad67a4 commit 891a4ad

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/classes/TaskRepository.cls

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,13 @@ public without sharing class TaskRepository extends SObjectRepository {
1515
return (Task)Database.query(query)[0];
1616
}
1717

18-
public Task getList(List<Id> taskIdList) {
18+
public List<Task> getList(List<Id> taskIdList) {
1919
String query = this
2020
.addConditionIdIn(taskIdList)
2121
.setAsUpdate(true)
2222
.getQuery();
2323

24-
return (Task)Database.query(query)[0];
24+
return (List<Task>)Database.query(query);
2525
}
2626

2727
public List<Task> getListOfOpenByWhoId(Id whoId) {

0 commit comments

Comments
 (0)