about summary refs log tree commit diff
path: root/app/controllers/api
diff options
context:
space:
mode:
authorLumb <lumb@git.multiple-creature.party>2019-06-20 09:43:14 +0000
committerGitea <gitea@fake.local>2019-07-17 07:08:14 +0000
commitb052644d2e06113f1ac685ff2263168f6827fedb (patch)
tree410c2c51793b8b63243afdea90d365e7f9ffa1b6 /app/controllers/api
parent5a93e171db3f28663ea23e8442dd5abf6674a435 (diff)
add search env to controller file
Add variable to controller file for search results
Diffstat (limited to 'app/controllers/api')
-rw-r--r--app/controllers/api/v1/search_controller.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/controllers/api/v1/search_controller.rb b/app/controllers/api/v1/search_controller.rb
index 639e71493..c62ca15c6 100644
--- a/app/controllers/api/v1/search_controller.rb
+++ b/app/controllers/api/v1/search_controller.rb
@@ -3,7 +3,7 @@
 class Api::V1::SearchController < Api::BaseController
   include Authorization
 
-  RESULTS_LIMIT = 100
+  RESULTS_LIMIT = (ENV['MAX_SEARCH_RESULTS'] || 100).to_i
 
   before_action -> { doorkeeper_authorize! :read, :'read:search' }
   before_action :require_user!