Details
-
Bug
-
Status: Closed
-
Resolution: Fixed
-
Master
-
7.2.x
-
Committed
-
3
Description
Description
@Override public List<FragmentEntry> getFragmentEntries( long groupId, long fragmentCollectionId, String name, int start, int end, OrderByComparator<FragmentEntry> orderByComparator) { if (Validator.isNull(name)) { return fragmentEntryPersistence.findByG_FCI( groupId, fragmentCollectionId, start, end, orderByComparator); } return fragmentEntryPersistence.findByG_FCI_LikeN( groupId, fragmentCollectionId, name, start, end, orderByComparator); }
We don't use wildcards in the name param for likeN, makin the getCall require an exact match instead of a partial, which makes no sense since 1, we are using an orderByComparator, so we should expect a orderByNameComparator to work as well. Even if this does technically work if you expect it to make exact fragmentEntry matches(for generating fragmentEntryKey could be one), this does seem like bad practice unless if there is a specific example where it is needed like this, but if so we should at least improve the name of the service to reduce confuability.
Expected Result
Wildcards appended to localService name paramter
Actual Result
Exact string match required for name paramter
Tested on Tomcat 9.0.10 + MySQL 5.7
Portal master GIT ID: eb2fa12bf6da50a6408c04e6050768a91600d301
Attachments
Issue Links
- is demanded by
-
LPS-96443 Create tests for FragmentEntryLocalService
-
- Closed
-