diff options
| author | mo khan <mo@mokhan.ca> | 2015-01-11 09:39:08 -0700 |
|---|---|---|
| committer | mo khan <mo@mokhan.ca> | 2015-01-11 09:39:08 -0700 |
| commit | 2b450d0c49da229768467953bbdba9687fc40ee5 (patch) | |
| tree | c7683a5d7f56cc40969c8d6176b1fe90d35faec4 /app/controllers/api | |
| parent | 227bdd2d5eb7532c5a5af7136f488fb410e1eabe (diff) | |
add tests for searching cakes.
Diffstat (limited to 'app/controllers/api')
| -rw-r--r-- | app/controllers/api/v2/cakes_controller.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/controllers/api/v2/cakes_controller.rb b/app/controllers/api/v2/cakes_controller.rb index ec38e753..4c85fd90 100644 --- a/app/controllers/api/v2/cakes_controller.rb +++ b/app/controllers/api/v2/cakes_controller.rb @@ -7,7 +7,7 @@ module Api end def index - @cakes = @repository.search_with(params).includes(:category).page(page).per(per_page) + @cakes = paginate(@repository.search_with(params).includes(:category)) end def show(id = params[:id]) |
