mirror of
https://github.com/discourse/discourse.git
synced 2025-01-19 03:12:46 +08:00
FIX: only send up to 100 selected tags in the tag search request to avoid sending a query string that's too long
This commit is contained in:
parent
b2b6dc68a6
commit
ce26f48f97
|
@ -109,12 +109,15 @@ export default Ember.TextField.extend({
|
|||
url: Discourse.getURL("/tags/filter/search"),
|
||||
dataType: 'json',
|
||||
data: function (term) {
|
||||
const selectedTags = self.get('tags');
|
||||
const d = {
|
||||
q: term,
|
||||
limit: self.siteSettings.max_tag_search_results,
|
||||
categoryId: self.get('categoryId'),
|
||||
selected_tags: self.get('tags')
|
||||
categoryId: self.get('categoryId')
|
||||
};
|
||||
if (selectedTags) {
|
||||
d.selected_tags = selectedTags.slice(0,100);
|
||||
}
|
||||
if (!self.get('everyTag')) {
|
||||
d.filterForInput = true;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user