Skip to content

Commit

Permalink
fix(search): 馃悰 always set label for search clients
Browse files Browse the repository at this point in the history
  • Loading branch information
alistair3149 committed Aug 4, 2023
1 parent b4d19dc commit 6fb2b1a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ function adaptApiResponse( config, query, response, showDescription ) {
const thumbnail = page.thumbnail;
return {
id: page.pageid,
label: page.from,
label: page.from || page.title,
key: page.title.replace( / /g, '_' ),
title: page.title,
description: showDescription ? getDescription( page ) : undefined,
Expand Down
2 changes: 1 addition & 1 deletion resources/skins.citizen.search/searchClients/mwRestApi.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ function adaptApiResponse( config, query, response, showDescription ) {
const thumbnail = page.thumbnail;
return {
id: page.id,
label: page.matched_title,
label: page.matched_title || page.title,
key: page.key,
title: page.title,
description: showDescription ? page.description : undefined,
Expand Down

0 comments on commit 6fb2b1a

Please sign in to comment.