diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2013-06-06 17:16:49 +0400 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2013-06-06 17:16:49 +0400 |
commit | cf9a366e22f731118b19de8a9922fb8df20e86a3 (patch) | |
tree | c804d28630461a859d7a14e0bfefe07c63f888d7 /lib/api/repositories.rb | |
parent | 883f465abe9df65a5186b358d0404f059b1f7a0d (diff) |
API: Fix repository commits pagination
Diffstat (limited to 'lib/api/repositories.rb')
-rw-r--r-- | lib/api/repositories.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/api/repositories.rb b/lib/api/repositories.rb index 2ed5ea20891..dc75ca7a383 100644 --- a/lib/api/repositories.rb +++ b/lib/api/repositories.rb @@ -94,7 +94,7 @@ module API get ":id/repository/commits" do authorize! :download_code, user_project - page = params[:page] || 0 + page = (params[:page] || 0).to_i per_page = (params[:per_page] || 20).to_i ref = params[:ref_name] || user_project.try(:default_branch) || 'master' |