-
Notifications
You must be signed in to change notification settings - Fork 91
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
SearchResultEntry: detect file results not from Files provider #762
Conversation
Some providers like FullTextSearch give file results without the fileId attribute. This refactor allows for that, otherwise they would crash the UnifiedSearch UI. Signed-off-by: Álvaro Brey Vilas <alvaro.brey@nextcloud.com>
sanitizer.parseUrl(resourceUrl) | ||
URL(resourceUrl).query?.let { sanitizer.parseQuery(it) } |
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.
Removed because we don't need to do this. parseUrl
already calls parseQuery
if present. Additionally this crashes when trying to parse paths that are not valid URLs (like files paths without the server).
/backport to stable-2.8 |
SpotBugs (new)
SpotBugs (master)
|
Codecov Report
@@ Coverage Diff @@
## master #762 +/- ##
==========================================
+ Coverage 46.33% 46.35% +0.02%
==========================================
Files 164 164
Lines 6354 6355 +1
Branches 834 833 -1
==========================================
+ Hits 2944 2946 +2
Misses 2971 2971
+ Partials 439 438 -1
|
If we need this, please create an issue in these repositories, so this will then work automatically at some point. |
|
Some providers like FullTextSearch give file results without the
fileId
attribute.This refactor allows for that, otherwise they would crash the UnifiedSearch UI.
Fixes nextcloud/android#9345