-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
description related to tag starting with name is removed #10521
base: develop
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -194,7 +194,7 @@ export default { | |
_inflight = {}; | ||
_taginfoCache = {}; | ||
_popularKeys = { | ||
// manually exclude some keys – #5377, #7485 | ||
// manually exclude some keys – #5377, #7485 | ||
postal_code: true, | ||
full_name: true, | ||
loc_name: true, | ||
|
@@ -222,7 +222,7 @@ export default { | |
this.keys(params, function(err, data) { | ||
if (err) return; | ||
data.forEach(function(d) { | ||
if (d.value === 'opening_hours') return; // exception | ||
if (d.value === 'opening_hours') return; //exception | ||
_popularKeys[d.value] = true; | ||
}); | ||
}); | ||
|
@@ -289,7 +289,7 @@ export default { | |
values: function(params, callback) { | ||
// Exclude popular keys from values lookups.. see #3955 | ||
var key = params.key; | ||
if (key && _popularKeys[key]) { | ||
if (key && _popularKeys[key] || key.slice(0,4)==='name') { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @1ec5 as you said that start with name: will cause to name that starting without colon shows suggestion, so do i change with this key.slice(0,4)==='name' to this => key.slice(0,5)==='name:' ?? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Now sir what I do : |
||
callback(null, []); | ||
return; | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was wondering how this service excludes
name
, since it isn’t explicitly listed in_popularKeys
. It turns out thatname
happens to be one of the 100 most popular keys that we add to the_popularKeys
here. (There’s some additional explanation at #7485 (comment) that I had forgotten.)