Replace long string with array and join (#795)
This commit is contained in:
parent
1672098388
commit
f2f889af77
1 changed files with 9 additions and 1 deletions
|
|
@ -12,7 +12,15 @@ module Api
|
|||
|
||||
def index
|
||||
@articles = ArticleApiIndexService.new(params).get
|
||||
set_surrogate_key_header "articles_api_#{params[:tag]}_#{params[:page]}_#{params[:userame]}_#{params[:signature]}_#{params[:state]}"
|
||||
key_headers = [
|
||||
"articles_api",
|
||||
params[:tag],
|
||||
params[:page],
|
||||
params[:userame],
|
||||
params[:signature],
|
||||
params[:state],
|
||||
]
|
||||
set_surrogate_key_header key_headers.join('_')
|
||||
end
|
||||
|
||||
def show
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue