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
[5.1][com_finder] check if finder content plugin is enabled #42299
Conversation
I am sorry to say, but the fix is wrong. What probably needed to fix #42296 is to do an addittional check, whether at least one plugin is enabled in the finder group. if (!PluginHelper::getPlugin('finder')) {
$this->app->enqueueMessage('No Finder plugin found, please enable at least one', 'warning');
} And this will be a new feature, not a bug fix. |
no problem, you are right I'll give it a closer look |
I don't think that this should go in 4.4 because it's not a bug. |
switched to 5.1 |
I have tested this item ✅ successfully on a455afe This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42299. |
should be aligned now |
I have tested this item ✅ successfully on 273a98d This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42299. |
1 similar comment
I have tested this item ✅ successfully on 273a98d This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42299. |
RTC This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42299. |
I have tested this item 🔴 unsuccessfully on 273a98d This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42299. |
I have tested this item 🔴 unsuccessfully on 273a98d This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42299. |
@dorisdreher Could you report back what has not worked? Maybe you've disabled the wrong plugins? Check also my previous comment. |
|
I have tested this item ✅ successfully on 273a98d This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42299. |
1 similar comment
I have tested this item ✅ successfully on 273a98d This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42299. |
@@ -148,6 +149,7 @@ COM_FINDER_INDEX_NO_DATA="No content has been indexed." | |||
COM_FINDER_INDEX_OPTIMISE_FINISHED="Optimisation finished." | |||
COM_FINDER_INDEX_PLUGIN_CONTENT_NOT_ENABLED="The Smart Search Content Plugin is disabled. Changes to content will not update the Smart Search index until the Plugin is enabled." | |||
COM_FINDER_INDEX_PLUGIN_CONTENT_NOT_ENABLED_LINK="The %s is disabled. Changes to content will not update the Smart Search index if you do not enable this plugin." | |||
COM_FINDER_INDEX_PLUGIN_FINDER_NOT_ENABLED_LINK="The %s are disabled. Changes to content will not update the Smart Search index if you do not enable these plugins." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can't we make one (new?) constant to cover both cases (as they have the same text) and deprecate the other two?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes we can
but out of scope of this pr
@@ -154,6 +163,11 @@ public function display($tpl = null) | |||
$this->finderPluginId = FinderHelper::getFinderPluginId(); | |||
} | |||
|
|||
// Check that the finder plugins are enabled | |||
if (!PluginHelper::getPlugin('finder')) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a personal opinion: I don't like this "loose" check here, but I'm aware that the getPlugin
method sucks in general (not fault of this PR).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i can agree with you,
but if my search results are not wrong
in core,
we already have more than 100 of this ...
out of scope of this pr
Pull Request for Issue #42296 .
Summary of Changes
correct the test if finder content plugin is enabled
Testing Instructions
Disable finder plugins, then start indexer
Actual result BEFORE applying this Pull Request
no message about disbled plugin
Expected result AFTER applying this Pull Request
message about disbled plugin
Link to documentations
Please select:
Documentation link for docs.joomla.org:
No documentation changes for docs.joomla.org needed
Pull Request link for manual.joomla.org:
No documentation changes for manual.joomla.org needed