Skip to content
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

Search page displays queried sentence even when parser is off. #1513

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions ext/js/dictionary/dictionary-importer.js
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change seems to have been accidentally pulled in. Please revert that.

Original file line number Diff line number Diff line change
Expand Up @@ -373,10 +373,9 @@ export class DictionaryImporter {
* @returns {ExtensionError}
*/
_formatAjvSchemaError(schema, fileName) {
const e2 = new ExtensionError(`Dictionary has invalid data in '${fileName}'`);
e2.data = schema.errors;

return e2;
const e = new ExtensionError(`Dictionary has invalid data in '${fileName}' '${JSON.stringify(schema.errors)}'`);
e.data = schema.errors;
return e;
}

/**
Expand Down
3 changes: 3 additions & 0 deletions ext/js/display/query-parser.js
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,9 @@ export class QueryParser extends EventDispatcher {
this._text = text;
this._setPreview(text);

if (this._useInternalParser === false && this._useMecabParser === false) {
return;
}
/** @type {?import('core').TokenObject} */
const token = {};
this._setTextToken = token;
Expand Down
Loading