aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/models
diff options
context:
space:
mode:
authorChocobozzz <florian.bigard@gmail.com>2016-06-06 14:54:52 +0200
committerChocobozzz <florian.bigard@gmail.com>2016-06-06 14:54:52 +0200
commit8d199cb823e1e47de87fdf421964e260b0ba6eb7 (patch)
tree563c5bd10235e69d84514a9b8348b525cc6d8765 /server/models
parentbe587647f98a4b83ca06a61fe55c7ac5d60927c6 (diff)
downloadPeerTube-8d199cb823e1e47de87fdf421964e260b0ba6eb7.tar.gz
PeerTube-8d199cb823e1e47de87fdf421964e260b0ba6eb7.tar.zst
PeerTube-8d199cb823e1e47de87fdf421964e260b0ba6eb7.zip
Add tag search support to server
Diffstat (limited to 'server/models')
-rw-r--r--server/models/videos.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/server/models/videos.js b/server/models/videos.js
index f4658c371..d6b743c7c 100644
--- a/server/models/videos.js
+++ b/server/models/videos.js
@@ -128,7 +128,7 @@ function removeByIds (ids, callback) {
128function search (value, field, start, count, sort, callback) { 128function search (value, field, start, count, sort, callback) {
129 const query = {} 129 const query = {}
130 // Make an exact search with the magnet 130 // Make an exact search with the magnet
131 if (field === 'magnetUri') { 131 if (field === 'magnetUri' || field === 'tags') {
132 query[field] = value 132 query[field] = value
133 } else { 133 } else {
134 query[field] = new RegExp(value) 134 query[field] = new RegExp(value)