mirror of
https://github.com/fallenbagel/jellyseerr.git
synced 2025-12-31 19:59:31 -05:00
fix(search): Handle search errors and escape * (#893)
This commit is contained in:
@@ -11,6 +11,7 @@ import { LanguageContext } from '../../context/LanguageContext';
|
||||
import { defineMessages, useIntl } from 'react-intl';
|
||||
import Header from '../Common/Header';
|
||||
import PageTitle from '../Common/PageTitle';
|
||||
import Error from '../../pages/_error';
|
||||
|
||||
const messages = defineMessages({
|
||||
search: 'Search',
|
||||
@@ -53,7 +54,7 @@ const Search: React.FC = () => {
|
||||
};
|
||||
|
||||
if (error) {
|
||||
return <div>{error}</div>;
|
||||
return <Error statusCode={error.code} />;
|
||||
}
|
||||
|
||||
const titles = data?.reduce(
|
||||
|
||||
@@ -11,6 +11,7 @@ const extraEncodes: [RegExp, string][] = [
|
||||
[/\(/g, '%28'],
|
||||
[/\)/g, '%29'],
|
||||
[/!/g, '%21'],
|
||||
[/\*/g, '%2A'],
|
||||
];
|
||||
|
||||
const encodeURIExtraParams = (string: string): string => {
|
||||
|
||||
Reference in New Issue
Block a user