make tag autocomplete endpoint expiry dynamic
This commit is contained in:
@@ -19,7 +19,7 @@ class TagsController < ApplicationController
|
||||
|
||||
def autocomplete
|
||||
@tags = Tag.names_matches_with_aliases(params[:search][:name_matches])
|
||||
expires_in 7.days
|
||||
expires_in params[:expiry].to_i.days if params[:expiry]
|
||||
|
||||
respond_with(@tags) do |format|
|
||||
format.xml do
|
||||
|
||||
Reference in New Issue
Block a user