Skip to content

Commit

Permalink
Update src/api/group/search-groups-with-name.ts
Browse files Browse the repository at this point in the history
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
  • Loading branch information
enc2586 and coderabbitai[bot] authored Jan 20, 2025
1 parent 6187763 commit ca3441c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/api/group/search-groups-with-name.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@ export interface GroupInfo {

export const searchGroupWithName = async (groupName: string, lang: Locale) => {
return await ziggleApi
.get<{ list: GroupInfo[] }>(`/group/search?query=${groupName}&lang=${lang}`)
.get<{ list: GroupInfo[] }>(`/group/search?query=${encodeURIComponent(groupName)}&lang=${lang}`)
.then(({ data: { list } }) => list);
};

0 comments on commit ca3441c

Please sign in to comment.