Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
VideoLAN
medialibrary
Commits
86bdf8b7
Commit
86bdf8b7
authored
Jan 21, 2016
by
Hugo Beauzée-Luyssen
Browse files
Media: Don't include non-present media in search results
parent
20a96d77
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/Media.cpp
View file @
86bdf8b7
...
...
@@ -434,6 +434,7 @@ std::vector<MediaPtr> Media::search( DBConnection dbConn, const std::string& tit
{
static
const
std
::
string
req
=
"SELECT * FROM "
+
policy
::
MediaTable
::
Name
+
" WHERE"
" id_media IN (SELECT rowid FROM "
+
policy
::
MediaTable
::
Name
+
"Fts"
" WHERE "
+
policy
::
MediaTable
::
Name
+
"Fts MATCH ?)"
;
" WHERE "
+
policy
::
MediaTable
::
Name
+
"Fts MATCH ?)"
"AND is_present = 1"
;
return
Media
::
fetchAll
<
IMedia
>
(
dbConn
,
req
,
title
+
"*"
);
}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment