We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 84114bb commit 57e23dbCopy full SHA for 57e23db
app/controllers/api/v1/posts_controller.rb
@@ -67,8 +67,8 @@ def destroy
67
private
68
# Use callbacks to share common setup or constraints between actions.
69
def comment_pagination_params
70
- @comment_page = params[:comment_page].present? ? params[:comment_page] : 1
71
- @comment_per = params[:comment_per].present? ? params[:comment_per] : Pagination.per
+ @comment_page = params[:comment_page].presence || 1
+ @comment_per = params[:comment_per].presence || Pagination.per
72
end
73
74
def set_post
0 commit comments