+ if (pagename === 'search' && params.has('q')) {
+ const arrTypeAndId = identifyLinkInQuery(params.get('q'));
+ if (arrTypeAndId instanceof Array) {
+ pagename = 'details';
+ params = new URLSearchParams();
+ params.set('osmtype', arrTypeAndId[0]);
+ params.set('osmid', arrTypeAndId[1]);
+ }
+ }
+