Commit 5c1cc1c22686b33c47e8b4fe60788bb961f04f91
1 parent
19bc212e
Exists in
staging
and in
10 other branches
refactoring tasks endpoint
Showing
1 changed file
with
1 additions
and
3 deletions
Show diff stats
app/api/v1/tasks.rb
| ... | ... | @@ -15,9 +15,7 @@ module Api |
| 15 | 15 | # Example Request: |
| 16 | 16 | # GET host/api/v1/tasks?from=2013-04-04-14:41:43&until=2015-04-04-14:41:43&limit=10&private_token=e96fff37c2238fdab074d1dcea8e6317 |
| 17 | 17 | get do |
| 18 | - tasks = select_filtered_collection_of(environment, 'tasks', params) | |
| 19 | - tasks = tasks.select {|t| current_person.has_permission?(t.permission, environment)} | |
| 20 | - present_partial tasks, :with => Entities::Task | |
| 18 | + present_tasks(environment) | |
| 21 | 19 | end |
| 22 | 20 | |
| 23 | 21 | desc "Return the task id" | ... | ... |